The test cases under the directory test-e2e are integration tests to ensure the correctness of the Submarine Workbench.
These test cases can be run either locally or on GitHub Actions.
Run E2E test locally
Ensure you have setup the submarine locally. If not, you can refer to
Submarine Local Deployment.
kubectl port-forward --address 0.0.0.0 service/submarine-traefik 32080:80
You need to modify the port and the URL in this script to where you run the workbench on.
Example: If your Submarine workbench is running on 127.0.0.1:4200, you should modify the WORKBENCH_PORT to 4200.
# at submarine-test/test_e2e/run_frontend_e2e.sh
# ======= Modifiable Variables ======= #
# Note: URL must start with "http"
# (Ref: https://www.selenium.dev/selenium/docs/api/java/org/openqa/selenium/WebDriver.html#get(java.lang.String))
WORKBENCH_PORT=8080 #<= modify this
URL="http://127.0.0.1" #<=modify this
# ==================================== #
Run run_frontend_e2e.sh (Run a specific test case)
This script will check whether the port can be accessed or not, and run the test case.
# at submarine-test/test_e2e
# TESTCASE is the IT you want to run, ex: loginIT, experimentIT...
Run all test cases
Following commands will compile all files and run all files ending with "IT" in the directory.
# Make sure the Submarine workbench is running on 127.0.0.1:8080
# Method 1:
# Method 2:
mvn clean install -U
Run E2E test in GitHub Actions
- Each time a commit is pushed, GitHub Actions will be triggered automatically.