Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

tests/e2e: give more controls to tests_runner.sh #265

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

wainersm
Copy link
Member

This makes the tests/e2e/tests_runner.sh more flexible so to improve the experience of debugging an error on tests. The new controls introduced are:

  • Exporting CI=false will disable the teardown of most Kata's tests. The clean up and revert routines won't execute, resources like pods are preserved.
  • You can filter only the tests you want to run by exporting the FILTER_TESTS variable. For example: $ export FILTER_TESTS='.*Test can pull an unencrypted image inside the guest'
  • Exporting KATA_TESTS_REPO_DIR it won't attempt to clone the tests repo. Notice that you should export GOPATH properly. Example: $ sudo -E PATH="$PATH" GOPATH=$PWD \ KATA_TESTS_REPO_DIR=$PWD/src/github.com/kata-containers/tests \ bash -c "./tests_runner.sh -r kata-qemu"

This makes the tests/e2e/tests_runner.sh more flexible so to improve the
experience of debugging an error on tests. The new controls introduced
are:

- Exporting `CI=false` will disable the teardown of most Kata's tests. The
  clean up and revert routines won't execute, resources like pods are preserved.
- You can filter only the tests you want to run by exporting the
  FILTER_TESTS variable. For example:
      $ export FILTER_TESTS='.*Test can pull an unencrypted image inside the guest'
- Exporting KATA_TESTS_REPO_DIR it won't attempt to clone the tests
  repo. Notice that you should export GOPATH properly. Example:
      $ sudo -E PATH="$PATH" GOPATH=$PWD \
            KATA_TESTS_REPO_DIR=$PWD/src/github.com/kata-containers/tests \
            bash -c "./tests_runner.sh -r kata-qemu"

Signed-off-by: Wainer dos Santos Moschetta <[email protected]>
@wainersm
Copy link
Member Author

This could have helped on debugging the tests for #263

Anyway, marking as do-not-merge to avoid putting more risks on the 0.8.0 release. If you wish to use this meanwhile, pick and put in your branch.

Cc @fidencio @stevenhorsman

@stevenhorsman
Copy link
Member

@wainersm - now we are decoupled from kata-containers tests in the operator I think this (or at least elements of it) isn't needed anymore?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants