-
-
Notifications
You must be signed in to change notification settings - Fork 363
50 lines (42 loc) · 1.41 KB
/
CI.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
49
50
name: CI
on: pull_request
jobs:
test:
runs-on: ubuntu-20.04
steps:
# Check out, and set up the node/ruby infra
- uses: actions/checkout@v3
- uses: actions/setup-node@v3
with:
node-version: "14"
# Get local dependencies & test
- run: yarn install
- run: yarn build
- run: yarn test
# Validate related tooling
- run: yarn declarations
- run: yarn tsc distribution/danger.d.ts
- run: rm -rf node_modules/@types/babel-*
- run: rm -rf node_modules/@types/babylon
# Not many Flow users nowadays, so this probably is worth dropping
# if it becomes an issue.
- run: echo "Testing Flow definition file"
- run: yarn build:flow-types
- run: echo "Running built Danger"
- run: node distribution/commands/danger-ci.js
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
- run: 'echo "This is only for Integration tests on two blank projects"'
- run: |
mkdir danger_blank_test
cd danger_blank_test
yarn init --yes
yarn add file:..
echo "warn('I warned you')" > dangerfile.js
echo "Testing a blank Dangerfile on an empty project"
DEBUG="*" yarn danger run --text-only
cd ..
rm -rf danger_blank_test
name: "Make danger_blank_test"
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}