Resolves "Update Scripted Test to Remove Dependency on Cypress Created UI Tests" | SKIP UPDATE
General MR
Summary
Per #233 (closed),
Previously this package's helm tests for Cypress created objects that became dependencies for this package's bash-based helm tests. This MR fixes that.
- rewrites
./chart/tests/scripts/test.shto not depend on objects created by the Cypress tests- leverages @jimmy.bourque's newly created
devops-testerimage to create its own admin token forcurl-based testing- uses
kubectlandjqfor that. - uses
skopeofor container image operations instead ofcranebecause the pipelines team is moving away fromcrane.
- uses
-
test.shcleans up after itself when complete: deletes new gitlab project and its images, deactivates its newly created temporaryroottoken.
- leverages @jimmy.bourque's newly created
- Rewrites the Cypress tests to delete the gitlab objects they created, meaning the
test.shtests can't depend on them anymore. - Chart preloads a paired
gitlab-test-pod-execRoleandRoleBindingto enable thetest.shscript tokubectl exec.-
test.shremoves thegitlab-test-pod-execRoleviakubectl deleteat the end of the test. It can't delete both theRoleand theRoleBindingbecause both of them have to exist in order to issue a delete command for either one. I chose to leave theRoleBindingin place and remove theRole. - n.b. this currently has to bind to the built-in account
system:serviceaccount:gitlab:default, while it should probably be binding to a gluon-specific namedServiceAccount. I've submitted an issue at gluon#40 (closed) to propose that as an option.
-
Relevant logs/screenshots
Tests passing in CI as desired!
Test log: https://repo1.dso.mil/big-bang/product/packages/gitlab/-/jobs/36286161
Linked Issue
- Closes gitlab#233
- Supersedes !281 (closed)
Upgrade Notices
N/A
Edited by Daniel Pritchett
