Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[DO NOT MERGE] test CI #2513

Open
wants to merge 1 commit into
base: main
Choose a base branch
from
Open
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
51 changes: 34 additions & 17 deletions .github/workflows/blossom-ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -20,12 +20,15 @@ on:
types: [created]
workflow_dispatch:
inputs:
platform:
description: 'runs-on argument'
required: false
args:
description: 'argument'
required: false
sha:
description: 'commit sha'
required: true
test_result:
description: 'test result'
required: true
test_results_url:
description: 'test results url'
required: true
jobs:
Authorization:
name: Authorization
Expand All @@ -35,7 +38,7 @@ jobs:

# This job only runs for pull request comments
if: |
github.event.comment.body == '/build' && (github.actor == 'niukuo' || github.actor == 'niukuo')
github.event.comment.body == '/build' && contains('["niukuo"]', github.actor)
steps:
- name: Check if comment is issued by authorized person
run: blossom-ci
Expand Down Expand Up @@ -78,14 +81,28 @@ jobs:
CI_SERVER: ${{ secrets.CI_SERVER }}
REPO_TOKEN: ${{ secrets.GITHUB_TOKEN }}

Upload-Log:
name: Upload log
runs-on: blossom
if : github.event_name == 'workflow_dispatch'
Upload-Test:
name: Upload test results
runs-on: niukuo
if: github.event_name == 'workflow_dispatch'
steps:
- name: Jenkins log for pull request ${{ fromJson(github.event.inputs.args).pr }} (click here)
run: blossom-ci
env:
OPERATION: 'POST-PROCESSING'
CI_SERVER: ${{ secrets.CI_SERVER }}
REPO_TOKEN: ${{ secrets.GITHUB_TOKEN }}
- name: Collect test result
run: rm -rf results && mkdir results && cd results && curl -L ${{ github.event.inputs.test_results_url }} | tar -xz
- name: Create test summary
id: test_summary
uses: test-summary/action@dist
with:
paths: results/**/results*.xml
- name: Update commit status
uses: actions/github-script@v6
with:
script: |
github.rest.repos.createCommitStatus({
owner: context.repo.owner,
repo: context.repo.repo,
context: 'blossom-ci',
sha: '${{ github.event.inputs.sha }}',
target_url: 'https://github.com/NVIDIA/TensorRT-LLM/actions/runs/' + context.runId,
state: '${{ steps.test_summary.outputs.failed > 0 && 'failure' || github.event.inputs.test_result || 'success' }}',
description: '${{ steps.test_summary.outputs.passed }} passed, ${{ steps.test_summary.outputs.failed }} failed, ${{ steps.test_summary.outputs.skipped }} skipped',
})