File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 66
77env :
88 REGISTRY : docker.io
9- IMAGE_BACKEND : mansi3133 /task-backend
10- IMAGE_FRONTEND : mansi3133 /task-frontend
9+ IMAGE_BACKEND : ${{ secrets.DOCKERHUB_USERNAME }} /task-backend
10+ IMAGE_FRONTEND : ${{ secrets.DOCKERHUB_USERNAME }} /task-frontend
1111
1212jobs :
1313 build-and-push :
4141 context : ./frontend
4242 push : true
4343 tags : ${{ env.IMAGE_FRONTEND }}:latest
44+
45+ e2e-tests :
46+ runs-on : ubuntu-latest
47+ needs : build-and-push
48+ steps :
49+ - name : Pull and run containers
50+ run : |
51+ docker run -d -p 4000:4000 --name backend ${{ secrets.DOCKERHUB_USERNAME }}/task-backend:latest
52+ docker run -d -p 5173:80 --name frontend ${{ secrets.DOCKERHUB_USERNAME }}/task-frontend:latest
53+
54+ - name : Wait for services
55+ run : |
56+ npx wait-on http://localhost:4000/tasks
57+ npx wait-on http://localhost:5173
58+
59+ - name : Run E2E Tests
60+ working-directory : e2e
61+ run : npx playwright test
You can’t perform that action at this time.
0 commit comments