Skip to content

Commit 2b84f8a

Browse files
authored
Merge pull request relay-tools#267 from n1ru4l/fix-tests
fix: bring package in a state where build and test do not fail
2 parents 1fc7a74 + 812d17e commit 2b84f8a

14 files changed

+319
-207
lines changed

.github/workflows/ci.yml

Lines changed: 25 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,25 @@
1+
name: CI
2+
on:
3+
push:
4+
jobs:
5+
ci:
6+
name: Continuous Integration
7+
runs-on: ubuntu-latest
8+
strategy:
9+
matrix:
10+
node-version: [10.x, 12.x, 14.x, 15.x]
11+
steps:
12+
- uses: actions/checkout@v2
13+
- uses: actions/setup-node@v2
14+
with:
15+
node-version: ${{ matrix.node-version }}
16+
- name: Cache node_modules
17+
id: cache-modules
18+
uses: actions/cache@v1
19+
with:
20+
path: node_modules
21+
key: ${{ matrix.node-version }}-${{ runner.OS }}-build-${{ hashFiles('yarn.lock') }}
22+
- run: yarn install
23+
- run: yarn test
24+
- run: yarn build
25+
- run: yarn lint

package.json

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,7 @@
3232
"lib"
3333
],
3434
"scripts": {
35-
"build": "rm -rf lib && tsc",
35+
"build": "rm -rf lib && tsc --project tsconfig.build.json",
3636
"lint": "tslint -c tslint.json --project tsconfig.json",
3737
"pr-check": "scripts/pr-check.sh",
3838
"prettier": "prettier --write '{src,types,test}/**/*.ts'",
@@ -41,7 +41,7 @@
4141
"sync-fixtures": "ts-node ./syncFixtures.ts",
4242
"test": "npm run type-check && jest",
4343
"type-check": "tsc --noEmit --pretty",
44-
"watch": "concurrently 'tsc --watch' 'chokidar \"lib/**/*.js\" -c \"yalc publish --force --push\"'"
44+
"watch": "concurrently 'tsc --watch --project tsconfig.build.json' 'chokidar \"lib/**/*.js\" -c \"yalc publish --force --push\"'"
4545
},
4646
"husky": {
4747
"hooks": {
@@ -77,6 +77,7 @@
7777
},
7878
"devDependencies": {
7979
"@artsy/auto-config": "^1.0.0",
80+
"@babel/runtime": "7.12.13",
8081
"@types/graphql": "^14.2.3",
8182
"@types/invariant": "2.2.34",
8283
"@types/jest": "^26.0.20",

0 commit comments

Comments
 (0)