Skip to content

Commit 80890db

Browse files
committed
arg to option.
1 parent 684bf58 commit 80890db

3 files changed

Lines changed: 8 additions & 8 deletions

File tree

Tests/kaas/sonobuoy_handler/run_sonobuoy.py

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -20,18 +20,18 @@ def cli():
2020
@click.option("-k", "--kubeconfig", "kubeconfig", required=True, type=click.Path(exists=True), help="path/to/kubeconfig_file.yaml",)
2121
@click.option("-r", "--result_dir_name", "result_dir_name", type=str, default="sonobuoy_results", help="directory name to store results at",)
2222
@click.option("-c", "--check", "check_name", type=str, default="sonobuoy_executor", help="this MUST be the same name as the id in 'scs-compatible-kaas.yaml'",)
23-
@click.option("--sonobuoy-config", "sonobuoy_config_yaml", type=click.Path(exists=True), default="kaas/sonobuoy-config.yaml", help="Configuration for Sonobuoy (yaml format)")
23+
@click.option("--scs-sonobuoy-config", "scs_sonobuoy_config_yaml", type=click.Path(exists=True), default="kaas/sonobuoy-config.yaml", help="Configuration for Sonobuoy (yaml format)")
2424
@click.option("-a", "--arg", "args", multiple=True)
25-
def sonobuoy_run(kubeconfig, result_dir_name, check_name, sonobuoy_config_yaml, args):
26-
sonobuoy_handler = SonobuoyHandler(check_name, kubeconfig, result_dir_name, sonobuoy_config_yaml, args)
25+
def sonobuoy_run(kubeconfig, result_dir_name, check_name, scs_sonobuoy_config_yaml, args):
26+
sonobuoy_handler = SonobuoyHandler(check_name, kubeconfig, result_dir_name, scs_sonobuoy_config_yaml, args)
2727
sys.exit(sonobuoy_handler.run())
2828

2929

3030
@cli.command("check-results")
31-
@click.argument("sonobuoy_config_yaml", type=click.Path(exists=True))
31+
@click.option("--scs-sonobuoy-config", "scs_sonobuoy_config_yaml", type=click.Path(exists=True), default="kaas/scs-sonobuoy-config.yaml", help="Configuration for Sonobuoy (yaml format)")
3232
@click.argument("sonobuoy_result_yaml", type=click.Path(exists=True))
33-
def check_results(sonobuoy_config_yaml, sonobuoy_result_yaml):
34-
check_sonobuoy_result(sonobuoy_config_yaml, sonobuoy_result_yaml)
33+
def check_results(scs_sonobuoy_config_yaml, sonobuoy_result_yaml):
34+
check_sonobuoy_result(scs_sonobuoy_config_yaml, sonobuoy_result_yaml)
3535
sys.exit(0)
3636

3737

Tests/scs-compatible-kaas.yaml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@ variables:
1111
- kubeconfig
1212
scripts:
1313
- executable: ./kaas/sonobuoy_handler/run_sonobuoy.py
14-
args: -k {kubeconfig} -r {subject_root}/sono-results-e2e -c 'cncf-k8s-conformance' -a '--mode=certified-conformance'
14+
args: run -k {kubeconfig} --scs-sonobuoy-config kaas/scs-sonobuoy-config.yaml -r {subject_root}/sono-results-e2e -c 'cncf-k8s-conformance' -a '--mode=certified-conformance'
1515
#~ args: -k {kubeconfig} -r {subject_root}/sono-results -c 'cncf-k8s-conformance' -a '--plugin-env e2e.E2E_DRYRUN=true'
1616
testcases:
1717
- id: cncf-k8s-conformance
@@ -31,7 +31,7 @@ scripts:
3131
description: Must fulfill all requirements of scs-0214-v2.
3232
url: https://docs.scs.community/standards/scs-0214-v2-k8s-node-distribution#decision
3333
- executable: ./kaas/sonobuoy_handler/run_sonobuoy.py
34-
args: -k {kubeconfig} -r {subject_root}/sono-results-0219 -c 'kaas-networking-check' -a '--e2e-focus "NetworkPolicy"'
34+
args: run -k {kubeconfig} --scs-sonobuoy-config kaas/scs-sonobuoy-config.yaml -r {subject_root}/sono-results-0219 -c 'kaas-networking-check' -a '--e2e-focus "NetworkPolicy"'
3535
testcases:
3636
- id: kaas-networking-check
3737
description: Must fulfill all requirements of scs-0219-v1.

0 commit comments

Comments
 (0)