Skip to content

Commit

Permalink
added docker compose file for restful ecommerce, updated testng.xml a…
Browse files Browse the repository at this point in the history
…nd maven.yml to run restfulecommerce tests in github actions
  • Loading branch information
mfaisalkhatri committed Sep 18, 2024
1 parent 6a90974 commit 048b4c2
Show file tree
Hide file tree
Showing 3 changed files with 15 additions and 0 deletions.
6 changes: 6 additions & 0 deletions .github/workflows/maven.yml
Original file line number Diff line number Diff line change
Expand Up @@ -37,6 +37,9 @@ jobs:
- name: Start restful booker service
run: docker compose -f ./docker-compose-restfulbooker.yml up -d

- name: Start restful e-commerce service
run: docker compose -f ./docker-compose-ecommerce.yml up -d

- name: Build Project
run: mvn clean install -DskipTests

Expand All @@ -46,6 +49,9 @@ jobs:
- name: Stop restful booker service
run: docker compose -f ./docker-compose-restfulbooker.yml down --remove-orphans

- name: Stop restful ecommerce service
run: docker compose -f ./docker-compose-ecommerce.yml down --remove-orphans

- name: Test Reporter
uses: dorny/[email protected]
if: always()
Expand Down
8 changes: 8 additions & 0 deletions docker-compose-ecommerce.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
# To execute this docker-compose yml file use `docker compose -f docker-compose-ecommerce.yml up -d`
# Add the `-d` flag at the end for detached execution
# To stop the execution, hit Ctrl+C, and then `docker compose -f docker-compose-ecommerce.yml down`
services:
restful-ecommerce:
image: mfaisalkhatri/restful-ecommerce
ports:
- 3004:3004
1 change: 1 addition & 0 deletions test-suite/testng.xml
Original file line number Diff line number Diff line change
Expand Up @@ -4,5 +4,6 @@
<suite-files>
<suite-file path="testng-reqres.xml"/>
<suite-file path="testng-restfulbooker.xml"/>
<suite-file path="testng-restfulecommerce.xml"/>
</suite-files>
</suite>

0 comments on commit 048b4c2

Please sign in to comment.