-
Notifications
You must be signed in to change notification settings - Fork 10
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[CI] Add comprehensive testing: migration, e2e, and bench (#30)
- Loading branch information
1 parent
4aa0ab8
commit 91a6454
Showing
48 changed files
with
803 additions
and
51 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,44 @@ | ||
name: bench_test | ||
|
||
on: | ||
push: | ||
branches: | ||
- main | ||
pull_request: | ||
branches: | ||
- main | ||
|
||
jobs: | ||
cancel_previous_workflows: | ||
runs-on: [self-hosted] | ||
timeout-minutes: 3 | ||
steps: | ||
- uses: styfle/cancel-workflow-action@0.12.1 | ||
with: | ||
all_but_latest: true | ||
|
||
bench_tests: | ||
needs: cancel_previous_workflows | ||
runs-on: [self-hosted] | ||
timeout-minutes: 60 | ||
steps: | ||
- name: Checkout | ||
uses: actions/checkout@v4 | ||
- name: Kill Running Containers | ||
run: | | ||
[[ -n $(docker ps -q) ]] && docker kill $(docker ps -q) || echo "No running containers to kill." | ||
- name: Build And Test | ||
run: ./tools/bench_test.sh | ||
- name: Create comment from file | ||
uses: actions/github-script@v7 | ||
with: | ||
script: | | ||
const fs = require('fs'); | ||
const filePath = 'performance.txt'; | ||
const commentBody = fs.readFileSync(filePath, 'utf8'); | ||
await github.rest.issues.createComment({ | ||
issue_number: context.issue.number, | ||
owner: context.repo.owner, | ||
repo: context.repo.repo, | ||
body: commentBody | ||
}); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,31 @@ | ||
name: e2e_test | ||
|
||
on: | ||
push: | ||
branches: | ||
- main | ||
pull_request: | ||
branches: | ||
- main | ||
|
||
jobs: | ||
cancel_previous_workflows: | ||
runs-on: [self-hosted] | ||
timeout-minutes: 3 | ||
steps: | ||
- uses: styfle/cancel-workflow-action@0.12.1 | ||
with: | ||
all_but_latest: true | ||
|
||
e2e_tests: | ||
needs: cancel_previous_workflows | ||
runs-on: [self-hosted] | ||
timeout-minutes: 60 | ||
steps: | ||
- name: Checkout | ||
uses: actions/checkout@v4 | ||
- name: Kill Running Containers | ||
run: | | ||
[[ -n $(docker ps -q) ]] && docker kill $(docker ps -q) || echo "No running containers to kill." | ||
- name: Build And Test | ||
run: ./tools/e2e_test.sh |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,44 @@ | ||
name: migration_test | ||
|
||
on: | ||
push: | ||
branches: | ||
- main | ||
pull_request: | ||
branches: | ||
- main | ||
|
||
jobs: | ||
cancel_previous_workflows: | ||
runs-on: [self-hosted] | ||
timeout-minutes: 3 | ||
steps: | ||
- uses: styfle/cancel-workflow-action@0.12.1 | ||
with: | ||
all_but_latest: true | ||
|
||
migration_tests: | ||
needs: cancel_previous_workflows | ||
runs-on: [self-hosted] | ||
timeout-minutes: 60 | ||
steps: | ||
- name: Checkout | ||
uses: actions/checkout@v4 | ||
- name: Kill Running Containers | ||
run: | | ||
[[ -n $(docker ps -q) ]] && docker kill $(docker ps -q) || echo "No running containers to kill." | ||
- name: Build And Test | ||
run: ./tools/migration_test.sh | ||
- name: Create comment from file | ||
uses: actions/github-script@v7 | ||
with: | ||
script: | | ||
const fs = require('fs'); | ||
const filePath = 'performance.txt'; | ||
const commentBody = fs.readFileSync(filePath, 'utf8'); | ||
await github.rest.issues.createComment({ | ||
issue_number: context.issue.number, | ||
owner: context.repo.owner, | ||
repo: context.repo.repo, | ||
body: commentBody | ||
}); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,32 @@ | ||
name: offline_inference | ||
|
||
on: | ||
push: | ||
branches: | ||
- main | ||
pull_request: | ||
branches: | ||
- main | ||
|
||
jobs: | ||
cancel_previous_workflows: | ||
runs-on: [self-hosted] | ||
timeout-minutes: 3 | ||
steps: | ||
- uses: styfle/cancel-workflow-action@0.12.1 | ||
with: | ||
all_but_latest: true | ||
|
||
offline_inference: | ||
needs: cancel_previous_workflows | ||
runs-on: [self-hosted] | ||
timeout-minutes: 10 | ||
steps: | ||
- uses: actions/checkout@v4 | ||
- name: Run offline inference example | ||
run: | | ||
nvidia-docker run --rm -t --net host --ipc host \ | ||
-v ${PWD}:/workspace \ | ||
-w /workspace \ | ||
registry.cn-beijing.aliyuncs.com/llumnix/llumnix-dev:20240909_action_678a439 \ | ||
bash -c "pip install -e . > /dev/null && python examlpes/offline_inference.py" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,31 @@ | ||
name: unit_test | ||
|
||
on: | ||
push: | ||
branches: | ||
- main | ||
pull_request: | ||
branches: | ||
- main | ||
|
||
jobs: | ||
cancel_previous_workflows: | ||
runs-on: [self-hosted] | ||
timeout-minutes: 3 | ||
steps: | ||
- uses: styfle/cancel-workflow-action@0.12.1 | ||
with: | ||
all_but_latest: true | ||
|
||
unit_tests: | ||
needs: cancel_previous_workflows | ||
runs-on: [self-hosted] | ||
timeout-minutes: 60 | ||
steps: | ||
- name: Checkout | ||
uses: actions/checkout@v4 | ||
- name: Kill Running Containers | ||
run: | | ||
[[ -n $(docker ps -q) ]] && docker kill $(docker ps -q) || echo "No running containers to kill." | ||
- name: Build And Test | ||
run: ./tools/unit_test.sh |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,26 @@ | ||
name: whl_build | ||
|
||
on: | ||
push: | ||
branches: | ||
- main | ||
pull_request: | ||
branches: | ||
- main | ||
|
||
jobs: | ||
whl_build: | ||
runs-on: ubuntu-latest | ||
timeout-minutes: 10 | ||
|
||
steps: | ||
- name: Checkout | ||
uses: actions/checkout@v4 | ||
- name: Set up Python | ||
uses: actions/setup-python@v5 | ||
with: | ||
python-version: "3.10" | ||
- name: Build whl | ||
run: | | ||
python3 -m pip install --upgrade setuptools wheel | ||
python3 setup.py bdist_wheel --universal |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,2 +1,2 @@ | ||
[pytest] | ||
asyncio_default_fixture_loop_scope = function | ||
asyncio_default_fixture_loop_scope = function |
Oops, something went wrong.