Details
-
Epic
-
Resolution: Done
-
Major
-
None
-
OSSM 2.5.0
-
None
-
False
-
None
-
False
-
0
-
0%
Description
The goal of this is to make the Cypress suite more self-contained by letting it detect if demo apps are installed and ready. If they are not present, they will be installed before running any Cypress test. We want to make the suite less dependent to the hack scripts. This will also help when it comes to the parallel execution.
Note: this may cause some suite inconsistencies related to different environments, but we are willing to take that risk.
The same approach was already used when it comes to the Gateway API setup:
https://github.com/kiali/kiali/pull/6105
This ticket is about detecting whether the specific app pod is ready to use.
There was also a request related to detecting generated traffic, but I'll cover that in a separate issue.
currently we install:
bookinfo app (bookinfo namespace) https://github.com/kiali/kiali/blob/d62bf6ee96b3abfc29989b4c37f31009e3d3472d/hack/istio/install-testing-demos.sh#LL161C5-L161C118
"${SCRIPT_DIR}/install-bookinfo-demo.sh" -c kubectl -mp ${MINIKUBE_PROFILE} -tg -in ${ISTIO_NAMESPACE} -a ${ARCH}
error rates (alpha and beta namespaces) https://github.com/kiali/kiali/blob/d62bf6ee96b3abfc29989b4c37f31009e3d3472d/hack/istio/install-testing-demos.sh#L157
"${SCRIPT_DIR}/install-error-rates-demo.sh" -c kubectl -in ${ISTIO_NAMESPACE} -a ${ARCH}
sleep app (sleep namespace) https://github.com/kiali/kiali/blob/master/hack/istio/install-testing-demos.sh#L14
install_sleep_app()
With mentioned above, we should call those scripts directly from cypress as pre test condition.
MVP here will be (I think) have install error rates and bookinfo scripts executed in parallel thru the cypress itself. To achieve that, we need to do some adjustments in shell scripts.
In this case, the scripts executed from cypress will do setup on all available environments (maistra vs istio) - therefore there is no need to implement this logic into cypress itself.
Currently scripts have some "test condition" that all apps are deployed OK, we might extend / reinforce that in shell scripts.
We can also add additional check into cypress itself after executing shell script - i.e.:
- cypress executes install-error-rates-demo.sh
- it verify that alpha and beta namespaces are present in UI
Attachments
Issue Links
- is related to
-
OSSM-4051 Make Cypress suite detect generated traffic before running the tests
-
- Backlog
-
- relates to
-
OSSM-4022 Check that demo apps are heathy before running kiali tests
-
- Closed
-
-
OSSM-4503 Investigate and update the Cypress hooks before running a regression on the multicluster
-
- Closed
-
- mentioned on