Skip to content

Commit

Permalink
Use appsharing for testing jupyterlite from PRs and galata reports (#188
Browse files Browse the repository at this point in the history
)
  • Loading branch information
martinRenou authored Oct 17, 2024
1 parent b9ec042 commit 3326473
Show file tree
Hide file tree
Showing 2 changed files with 49 additions and 0 deletions.
14 changes: 14 additions & 0 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -194,6 +194,7 @@ jobs:
run: npx playwright test --retries=2

- name: Upload Playwright Test report
id: upload-galata-artifact
if: always()
uses: actions/upload-artifact@v3
with:
Expand All @@ -202,6 +203,13 @@ jobs:
ui-tests/test-results
ui-tests/playwright-report
- name: Save artifact data
if: always()
uses: trungleduc/appsharingspace-pr-comment/.github/actions/save-artifact-link@v2
with:
output_name: galata-apss
artifact_link: 'https://github.com/${{ github.repository }}/actions/runs/${{github.run_id}}/artifacts/${{ steps.upload-galata-artifact.outputs.artifact-id }}'

check_linting:
name: Lint check
runs-on: ubuntu-latest
Expand Down Expand Up @@ -276,11 +284,17 @@ jobs:
jupyter lite build --contents content --output-dir dist
- name: Upload artifact
id: upload-jupyterlite-artifact
uses: actions/upload-pages-artifact@v3
with:
path: ./lite/dist
retention-days: 30

- name: Save artifact data
uses: trungleduc/appsharingspace-pr-comment/.github/actions/save-artifact-link@v2
with:
artifact_link: 'https://github.com/${{ github.repository }}/actions/runs/${{github.run_id}}/artifacts/${{ steps.upload-jupyterlite-artifact.outputs.artifact_id }}'

deploy:
needs: build-lite
if: github.ref == 'refs/heads/main'
Expand Down
35 changes: 35 additions & 0 deletions .github/workflows/comment-on-pr.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,35 @@
name: Add preview link to PR

on:
workflow_run:
workflows: ['Build']
types:
- completed

permissions:
pull-requests: write

jobs:
comment-preview:
runs-on: ubuntu-latest
if: >
${{ github.event.workflow_run.event == 'pull_request' &&
github.event.workflow_run.conclusion == 'success' }}
steps:
- name: 'Comment APSS link on workflow'
uses: trungleduc/appsharingspace-pr-comment/.github/actions/pr-comment@v2
with:
github_token: ${{ secrets.github_token }}
index_path: lab/index.html
comment-galata:
runs-on: ubuntu-latest
if: >
${{ github.event.workflow_run.event == 'pull_request'}}
steps:
- name: 'Comment galata link on workflow'
uses: trungleduc/appsharingspace-pr-comment/.github/actions/pr-comment@v2
with:
comment_prefix: '**Integration tests repot:**'
artifact_name: galata-apss
github_token: ${{ secrets.github_token }}
index_path: playwright-report/index.html

0 comments on commit 3326473

Please sign in to comment.