Skip to content

Commit

Permalink
Pass env to tests.
Browse files Browse the repository at this point in the history
  • Loading branch information
jmoseley committed Jan 7, 2025
1 parent 809bbf9 commit 7c2090e
Show file tree
Hide file tree
Showing 5 changed files with 21 additions and 2 deletions.
4 changes: 4 additions & 0 deletions .github/workflows/lint-pr-title.yml
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,10 @@ on:
permissions:
pull-requests: write

concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: true

jobs:
main:
name: Validate PR title
Expand Down
4 changes: 4 additions & 0 deletions .github/workflows/lint.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,10 @@ permissions:
checks: write
pull-requests: write

concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: true

jobs:
lint:
runs-on: ubuntu-latest
Expand Down
4 changes: 4 additions & 0 deletions .github/workflows/test-examples.yml
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,10 @@ permissions:
checks: write
pull-requests: write

concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: true

jobs:
build:
runs-on: ubuntu-latest
Expand Down
8 changes: 7 additions & 1 deletion .github/workflows/test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,10 @@ permissions:
checks: write
pull-requests: write

concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: true

jobs:
build:
runs-on: ubuntu-latest
Expand All @@ -34,9 +38,11 @@ jobs:

- name: Run tests 🧪
run: pnpm test
env:
OPENAI_API_KEY: ${{ secrets.OPENAI_API_KEY }}

- name: Report GenSX Coverage 📊
if: github.event_name == 'pull_request' && matrix.node-version == '20.x'
if: github.event_name == 'pull_request' && matrix.node-version == '20.x' && contains(github.event.pull_request.changed_files, 'packages/gensx')
uses: davelosert/vitest-coverage-report-action@v2
with:
working-directory: packages/gensx
Expand Down
3 changes: 2 additions & 1 deletion turbo.json
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,8 @@
"dependsOn": ["^build", "build"]
},
"create-gensx#test": {
"dependsOn": ["^build", "build", "gensx#build", "@gensx/openai#build"]
"dependsOn": ["^build", "build", "gensx#build", "@gensx/openai#build"],
"env": ["OPENAI_API_KEY"]
}
}
}

0 comments on commit 7c2090e

Please sign in to comment.