Support environment variables as parameter #704
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
The issue resolved by this Pull Request:
Break down the solution for #RHOAIENG-10212 into smaller PRs to facilitate review.
Description of your changes:
CLEANUP
flag allows for optional resource cleanup before the tests. Useful while retrying the test in the OpenShift environment. The final cleanup solution will be discussed in other PR.K8SAPISERVERHOST
variable provides more flexibility, enabling it to be set via a command line argument, rather than being hardcoded within the test functions."DSPA_NAME
andDSPA_EXTERNAL_NAME
as redundant variables, simplifying namespace handling by directly usingDSPA_NAMESPACE
andDSPA_EXTERNAL_NAMESPACE
. This removes unnecessary duplication.kubectl whoami --show-server
forK8SAPISERVERHOST
in the run_tests and run_tests_dspa_external_connections functions. This allows the user to defineK8SAPISERVERHOST
explicitly via command line arguments, offering better control over the testing environment, especially for air-gapped setups.DSPA_NAMESPACE
andDSPA_EXTERNAL_NAMESPACE
during the resource cleanup process. Ensures that all test-related namespaces are properly cleaned up.run_kind_tests
tosetup_kind_requirements
andrun_rhoai_tests
tosetup_rhoai_requirements
. This better reflects their functionality as preparation steps rather than test execution steps. Testing is now decoupled from resource setup.--cleanup, --k8s-api-server-host, --dspa-namespace, and --dspa-path
. This allows users to customize their test environments more dynamically when running the script.Testing instructions
Checklist