[Bug] Changing log verbosity level has no effect on the `test` command
chipzoller opened this issue · comments
What happened:
Adding the -v
flag to the test
command shows no difference in the output regardless of the configured level.
What you expected to happen:
Per the command output of kuttl test -h
, I expect more verbose output when adding the -v
flag and increasing the level.
How to reproduce it (as minimally and precisely as possible):
Show example output below of stepping up the -v
flag's argument from 0
to 4
:
k kuttl test --test steps-clusterpolicy -v 0 .
2022/11/13 11:14:46 running without a 'kuttl-test.yaml' configuration
2022/11/13 11:14:46 kutt-test config testdirs is overridden with args: [ . ]
=== RUN kuttl
harness.go:459: starting setup
harness.go:250: running tests using configured kubeconfig.
harness.go:287: Successful connection to cluster at: https://0.0.0.0:61294
harness.go:355: running tests
harness.go:73: going to run test suite with timeout of 30 seconds for each step
harness.go:367: testsuite: . has 4 tests
=== RUN kuttl/harness
=== RUN kuttl/harness/steps-clusterpolicy
=== PAUSE kuttl/harness/steps-clusterpolicy
=== CONT kuttl/harness/steps-clusterpolicy
logger.go:42: 11:14:48 | steps-clusterpolicy | Ignoring cpol-assert.yaml as it does not match file name regexp: ^(\d+)-(?:[^\.]+)(?:\.yaml)?$
logger.go:42: 11:14:48 | steps-clusterpolicy | Ignoring cpol-error.yaml as it does not match file name regexp: ^(\d+)-(?:[^\.]+)(?:\.yaml)?$
logger.go:42: 11:14:48 | steps-clusterpolicy | Ignoring cpol.yaml as it does not match file name regexp: ^(\d+)-(?:[^\.]+)(?:\.yaml)?$
logger.go:42: 11:14:48 | steps-clusterpolicy | Creating namespace: kuttl-test-aware-wombat
logger.go:42: 11:14:48 | steps-clusterpolicy/1-apply | starting test step 1-apply
logger.go:42: 11:14:49 | steps-clusterpolicy/1-apply | ClusterPolicy:/require-labels created
logger.go:42: 11:14:49 | steps-clusterpolicy/1-apply | test step completed 1-apply
Warning: events.k8s.io/v1beta1 Event is deprecated in v1.22+, unavailable in v1.25+
logger.go:42: 11:14:49 | steps-clusterpolicy | steps-clusterpolicy events from ns kuttl-test-aware-wombat:
logger.go:42: 11:14:49 | steps-clusterpolicy | Deleting namespace: kuttl-test-aware-wombat
=== CONT kuttl
harness.go:401: run tests finished
harness.go:510: cleaning up
harness.go:567: removing temp folder: ""
--- PASS: kuttl (2.42s)
--- PASS: kuttl/harness (0.00s)
--- PASS: kuttl/harness/steps-clusterpolicy (0.71s)
PASS
➜ kuttl git:(master) ✗ k kuttl test --test steps-clusterpolicy -v 1 .
2022/11/13 11:14:55 running without a 'kuttl-test.yaml' configuration
2022/11/13 11:14:55 kutt-test config testdirs is overridden with args: [ . ]
=== RUN kuttl
harness.go:459: starting setup
harness.go:250: running tests using configured kubeconfig.
harness.go:287: Successful connection to cluster at: https://0.0.0.0:61294
harness.go:355: running tests
harness.go:73: going to run test suite with timeout of 30 seconds for each step
harness.go:367: testsuite: . has 4 tests
=== RUN kuttl/harness
=== RUN kuttl/harness/steps-clusterpolicy
=== PAUSE kuttl/harness/steps-clusterpolicy
=== CONT kuttl/harness/steps-clusterpolicy
logger.go:42: 11:14:57 | steps-clusterpolicy | Ignoring cpol-assert.yaml as it does not match file name regexp: ^(\d+)-(?:[^\.]+)(?:\.yaml)?$
logger.go:42: 11:14:57 | steps-clusterpolicy | Ignoring cpol-error.yaml as it does not match file name regexp: ^(\d+)-(?:[^\.]+)(?:\.yaml)?$
logger.go:42: 11:14:57 | steps-clusterpolicy | Ignoring cpol.yaml as it does not match file name regexp: ^(\d+)-(?:[^\.]+)(?:\.yaml)?$
logger.go:42: 11:14:57 | steps-clusterpolicy | Creating namespace: kuttl-test-alive-alien
logger.go:42: 11:14:57 | steps-clusterpolicy/1-apply | starting test step 1-apply
logger.go:42: 11:14:57 | steps-clusterpolicy/1-apply | ClusterPolicy:/require-labels created
logger.go:42: 11:14:57 | steps-clusterpolicy/1-apply | test step completed 1-apply
Warning: events.k8s.io/v1beta1 Event is deprecated in v1.22+, unavailable in v1.25+
logger.go:42: 11:14:57 | steps-clusterpolicy | steps-clusterpolicy events from ns kuttl-test-alive-alien:
logger.go:42: 11:14:57 | steps-clusterpolicy | Deleting namespace: kuttl-test-alive-alien
=== CONT kuttl
harness.go:401: run tests finished
harness.go:510: cleaning up
harness.go:567: removing temp folder: ""
--- PASS: kuttl (2.38s)
--- PASS: kuttl/harness (0.00s)
--- PASS: kuttl/harness/steps-clusterpolicy (0.71s)
PASS
➜ kuttl git:(master) ✗ k kuttl test --test steps-clusterpolicy -v 2 .
2022/11/13 11:15:00 running without a 'kuttl-test.yaml' configuration
2022/11/13 11:15:00 kutt-test config testdirs is overridden with args: [ . ]
=== RUN kuttl
harness.go:459: starting setup
harness.go:250: running tests using configured kubeconfig.
harness.go:287: Successful connection to cluster at: https://0.0.0.0:61294
harness.go:355: running tests
harness.go:73: going to run test suite with timeout of 30 seconds for each step
harness.go:367: testsuite: . has 4 tests
=== RUN kuttl/harness
=== RUN kuttl/harness/steps-clusterpolicy
=== PAUSE kuttl/harness/steps-clusterpolicy
=== CONT kuttl/harness/steps-clusterpolicy
logger.go:42: 11:15:02 | steps-clusterpolicy | Ignoring cpol-assert.yaml as it does not match file name regexp: ^(\d+)-(?:[^\.]+)(?:\.yaml)?$
logger.go:42: 11:15:02 | steps-clusterpolicy | Ignoring cpol-error.yaml as it does not match file name regexp: ^(\d+)-(?:[^\.]+)(?:\.yaml)?$
logger.go:42: 11:15:02 | steps-clusterpolicy | Ignoring cpol.yaml as it does not match file name regexp: ^(\d+)-(?:[^\.]+)(?:\.yaml)?$
logger.go:42: 11:15:02 | steps-clusterpolicy | Creating namespace: kuttl-test-advanced-boxer
logger.go:42: 11:15:02 | steps-clusterpolicy/1-apply | starting test step 1-apply
logger.go:42: 11:15:02 | steps-clusterpolicy/1-apply | ClusterPolicy:/require-labels created
logger.go:42: 11:15:02 | steps-clusterpolicy/1-apply | test step completed 1-apply
Warning: events.k8s.io/v1beta1 Event is deprecated in v1.22+, unavailable in v1.25+
logger.go:42: 11:15:02 | steps-clusterpolicy | steps-clusterpolicy events from ns kuttl-test-advanced-boxer:
logger.go:42: 11:15:02 | steps-clusterpolicy | Deleting namespace: kuttl-test-advanced-boxer
=== CONT kuttl
harness.go:401: run tests finished
harness.go:510: cleaning up
harness.go:567: removing temp folder: ""
--- PASS: kuttl (2.41s)
--- PASS: kuttl/harness (0.00s)
--- PASS: kuttl/harness/steps-clusterpolicy (0.73s)
PASS
➜ kuttl git:(master) ✗ k kuttl test --test steps-clusterpolicy -v 3 .
2022/11/13 11:15:05 running without a 'kuttl-test.yaml' configuration
2022/11/13 11:15:05 kutt-test config testdirs is overridden with args: [ . ]
=== RUN kuttl
harness.go:459: starting setup
harness.go:250: running tests using configured kubeconfig.
harness.go:287: Successful connection to cluster at: https://0.0.0.0:61294
harness.go:355: running tests
harness.go:73: going to run test suite with timeout of 30 seconds for each step
harness.go:367: testsuite: . has 4 tests
=== RUN kuttl/harness
=== RUN kuttl/harness/steps-clusterpolicy
=== PAUSE kuttl/harness/steps-clusterpolicy
=== CONT kuttl/harness/steps-clusterpolicy
logger.go:42: 11:15:07 | steps-clusterpolicy | Ignoring cpol-assert.yaml as it does not match file name regexp: ^(\d+)-(?:[^\.]+)(?:\.yaml)?$
logger.go:42: 11:15:07 | steps-clusterpolicy | Ignoring cpol-error.yaml as it does not match file name regexp: ^(\d+)-(?:[^\.]+)(?:\.yaml)?$
logger.go:42: 11:15:07 | steps-clusterpolicy | Ignoring cpol.yaml as it does not match file name regexp: ^(\d+)-(?:[^\.]+)(?:\.yaml)?$
logger.go:42: 11:15:07 | steps-clusterpolicy | Creating namespace: kuttl-test-one-ray
logger.go:42: 11:15:07 | steps-clusterpolicy/1-apply | starting test step 1-apply
logger.go:42: 11:15:07 | steps-clusterpolicy/1-apply | ClusterPolicy:/require-labels created
logger.go:42: 11:15:07 | steps-clusterpolicy/1-apply | test step completed 1-apply
Warning: events.k8s.io/v1beta1 Event is deprecated in v1.22+, unavailable in v1.25+
logger.go:42: 11:15:07 | steps-clusterpolicy | steps-clusterpolicy events from ns kuttl-test-one-ray:
logger.go:42: 11:15:07 | steps-clusterpolicy | Deleting namespace: kuttl-test-one-ray
=== CONT kuttl
harness.go:401: run tests finished
harness.go:510: cleaning up
harness.go:567: removing temp folder: ""
--- PASS: kuttl (2.41s)
--- PASS: kuttl/harness (0.00s)
--- PASS: kuttl/harness/steps-clusterpolicy (0.73s)
PASS
➜ kuttl git:(master) ✗ k kuttl test --test steps-clusterpolicy -v 4 .
2022/11/13 11:15:10 running without a 'kuttl-test.yaml' configuration
2022/11/13 11:15:10 kutt-test config testdirs is overridden with args: [ . ]
=== RUN kuttl
harness.go:459: starting setup
harness.go:250: running tests using configured kubeconfig.
harness.go:287: Successful connection to cluster at: https://0.0.0.0:61294
harness.go:355: running tests
harness.go:73: going to run test suite with timeout of 30 seconds for each step
harness.go:367: testsuite: . has 4 tests
=== RUN kuttl/harness
=== RUN kuttl/harness/steps-clusterpolicy
=== PAUSE kuttl/harness/steps-clusterpolicy
=== CONT kuttl/harness/steps-clusterpolicy
logger.go:42: 11:15:12 | steps-clusterpolicy | Ignoring cpol-assert.yaml as it does not match file name regexp: ^(\d+)-(?:[^\.]+)(?:\.yaml)?$
logger.go:42: 11:15:12 | steps-clusterpolicy | Ignoring cpol-error.yaml as it does not match file name regexp: ^(\d+)-(?:[^\.]+)(?:\.yaml)?$
logger.go:42: 11:15:12 | steps-clusterpolicy | Ignoring cpol.yaml as it does not match file name regexp: ^(\d+)-(?:[^\.]+)(?:\.yaml)?$
logger.go:42: 11:15:12 | steps-clusterpolicy | Creating namespace: kuttl-test-fancy-parakeet
logger.go:42: 11:15:12 | steps-clusterpolicy/1-apply | starting test step 1-apply
logger.go:42: 11:15:12 | steps-clusterpolicy/1-apply | ClusterPolicy:/require-labels created
logger.go:42: 11:15:12 | steps-clusterpolicy/1-apply | test step completed 1-apply
Warning: events.k8s.io/v1beta1 Event is deprecated in v1.22+, unavailable in v1.25+
logger.go:42: 11:15:12 | steps-clusterpolicy | steps-clusterpolicy events from ns kuttl-test-fancy-parakeet:
logger.go:42: 11:15:12 | steps-clusterpolicy | Deleting namespace: kuttl-test-fancy-parakeet
=== CONT kuttl
harness.go:401: run tests finished
harness.go:510: cleaning up
harness.go:567: removing temp folder: ""
--- PASS: kuttl (2.39s)
--- PASS: kuttl/harness (0.00s)
--- PASS: kuttl/harness/steps-clusterpolicy (0.71s)
PASS
Anything else we need to know?:
Environment:
- Kubernetes version (use
kubectl version
): - KUTTL version (use
kubectl kuttl version
): 0.14 - Cloud provider or hardware configuration:
- OS (e.g. from /etc/os-release):
- Kernel (e.g.
uname -a
): - Install tools:
- Others: