-
Notifications
You must be signed in to change notification settings - Fork 57
48 lines (39 loc) · 1.1 KB
/
test-pr.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
name: Test PR
on:
pull_request_target:
branches:
- main
jobs:
approve:
runs-on: ubuntu-latest
steps:
- name: Approval required.
run: echo For security reasons, all pull requests need to be approved first before running any automated CI.
test-branch:
name: run-tests
runs-on: ubuntu-latest
needs: [approve]
environment: OPENAI
env:
OPENAI_API_KEY: ${{ secrets.OPENAI_API_KEY }}
ANYSCALE_API_KEY: ${{ secrets.ANYSCALE_API_KEY }}
TOGETHER_API_KEY: ${{ secrets.TOGETHER_API_KEY }}
ANTHROPIC_API_KEY: ${{ secrets.ANTHROPIC_API_KEY }}
steps:
- uses: actions/checkout@v3
with:
ref: ${{ github.event.pull_request.head.sha }}
fetch-depth: 2
- name: Setup bun
uses: oven-sh/setup-bun@v1
with:
bun-version: latest
- name: Setup Node.js
uses: actions/setup-node@v3
with:
node-version: 20.9.0
- name: Install Dependencies
run: bun i
- run: bun run type-check
- run: bun run lint
- run: bun test --timeout=25000