File tree Expand file tree Collapse file tree 1 file changed +10
-3
lines changed Expand file tree Collapse file tree 1 file changed +10
-3
lines changed Original file line number Diff line number Diff line change @@ -18,7 +18,7 @@ wait_for_service() {
18
18
}
19
19
20
20
cleanup () {
21
- git restore backend.json
21
+ git restore .
22
22
if test -n " $PID_MKDOCS " ; then
23
23
echo " Stopping mkdocs at PID $PID_MKDOCS "
24
24
pkill -P " $PID_MKDOCS "
@@ -29,15 +29,22 @@ cleanup() {
29
29
fi
30
30
}
31
31
32
- # Starts frontend and backend and ensures they are stopped when the script exits
32
+ # Ensures frontend and backend are stopped when the script exits
33
33
trap cleanup EXIT
34
+
35
+ # Start frontend in the background
36
+ cp backend.local.json backend.json
37
+ npx webpack --mode=development
34
38
" $SCRIPT_DIR /../../serve-no-livereload.sh" &
35
39
PID_MKDOCS=$!
40
+
41
+ # Start backend in the background
36
42
docker run --rm -p 8080:8080 ghcr.io/epsilonlabs/playground-backend:standalone-server &
37
43
PID_DOCKER=$!
38
44
45
+ # Wait for both to finish starting
39
46
wait_for_service Frontend 8000
40
47
wait_for_service Backend 8080
41
48
42
- cp backend.local.json backend.json
49
+ # Run Cypress tests
43
50
npx cypress run --browser firefox --spec " cypress/e2e/*.cy.js" " $@ "
You can’t perform that action at this time.
0 commit comments