Skip to content
This repository was archived by the owner on Nov 24, 2025. It is now read-only.
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@
under the License.
-->

# tr-tests Docker action
# tr-unit-tests Docker action
This action runs the Traffic Router unit tests in an Alpine Docker container.

## Inputs
Expand All @@ -43,12 +43,12 @@ jobs:
restore-keys: |
${{ runner.os }}-maven-
- name: Run unit tests
uses: ./.github/actions/tr-tests
uses: ./.github/actions/tr-unit-tests
```

To run the tests locally:
```shell
export GITHUB_WORKSPACE='/github/workspace';
docker build -f .github/actions/tr-tests/Dockerfile -t tr-unit-tests .;
docker build -f .github/actions/tr-unit-tests/Dockerfile -t tr-unit-tests .;
docker run --rm -te GITHUB_WORKSPACE -v "$(pwd):${GITHUB_WORKSPACE}" -w "$GITHUB_WORKSPACE" tr-unit-tests;
```
8 changes: 4 additions & 4 deletions .github/workflows/tr.unit.tests.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -24,13 +24,13 @@ env:
on:
push:
paths:
- .github/actions/tr-tests/**
- .github/actions/tr-unit-tests/**
- .github/workflows/tr.unit.tests.yaml
- traffic_router/**
create:
pull_request:
paths:
- .github/actions/tr-tests/**
- .github/actions/tr-unit-tests/**
- .github/workflows/tr.unit.tests.yaml
- traffic_router/**
types: [ opened, reopened, ready_for_review, synchronize ]
Expand All @@ -56,8 +56,8 @@ jobs:
key: ${{ runner.os }}-maven-${{ hashFiles('**/pom.xml') }}
restore-keys: |
${{ runner.os }}-maven-
- name: Run unit tests
uses: ./.github/actions/tr-tests
- name: Run Traffic Router unit tests
uses: ./.github/actions/tr-unit-tests
- name: Upload Surefire Reports
uses: actions/upload-artifact@v2
if: ${{ failure() }}
Expand Down