chore(build): fix github actions (#44)

* Add nvmrc to app

* Add nvmrc to api

* Remove unused test in app

* Fix broken test in site

* chore: use yarn instead of npm

* chore: setup lerna to use yarn

* chore(build): use yarn in workflows

* chore(build): skip lerna install and run using npx
This commit is contained in:
Rickard Natt och Dag 2021-02-08 13:22:32 +01:00 committed by GitHub
parent 1e45d283ab
commit d8f106f60f
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
15 changed files with 28961 additions and 28391 deletions

View File

@ -16,11 +16,9 @@ jobs:
uses: actions/setup-node@v1
- name: Install dependencies
run: |
npm i -g lerna
lerna bootstrap
run: npx lerna bootstrap
- name: Run tests
run: npm test
run: yarn test
env:
CI: true

View File

@ -17,11 +17,9 @@ jobs:
uses: actions/setup-node@v1
- name: Install dependencies
run: |
npm i -g lerna
lerna bootstrap
run: npx lerna bootstrap
- name: Run tests
run: npm test
run: yarn test
env:
CI: true

View File

@ -1,6 +1,6 @@
{
"packages": [
"packages/*"
],
"packages": ["packages/*"],
"npmClient": "yarn",
"useWorkspaces": true,
"version": "0.0.0"
}

7035
package-lock.json generated

File diff suppressed because it is too large Load Diff

View File

@ -6,5 +6,8 @@
},
"scripts": {
"test": "lerna run test --stream"
}
},
"workspaces": [
"packages/*"
]
}

1
packages/api/.nvmrc Normal file
View File

@ -0,0 +1 @@
v14.15.0

File diff suppressed because it is too large Load Diff

5499
packages/api/yarn.lock Normal file

File diff suppressed because it is too large Load Diff

1
packages/app/.nvmrc Normal file
View File

@ -0,0 +1 @@
v14.15.4

View File

@ -1,14 +0,0 @@
/**
* @format
*/
import 'react-native'
import React from 'react'
import App from '../App'
// Note: test renderer must be required after react-native.
import renderer from 'react-test-renderer'
it('renders correctly', () => {
renderer.create(<App />)
})

View File

@ -7,7 +7,7 @@
"ios": "react-native-fix-image && react-native run-ios",
"pod": "npx pod-install",
"start": "react-native start",
"test": "jest",
"test": "jest --passWithNoTests",
"lint": "eslint ."
},
"dependencies": {

View File

@ -2,6 +2,12 @@ import React from 'react'
import { render, screen, fireEvent } from '@testing-library/react'
import Header from '../Header'
jest.mock('next/router', () => ({
useRouter: jest.fn().mockReturnValue({
pathname: '',
}),
}))
const setup = (customProps = {}) => {
const props = {
...customProps,

File diff suppressed because it is too large Load Diff

8050
packages/site/yarn.lock Normal file

File diff suppressed because it is too large Load Diff

15392
yarn.lock Normal file

File diff suppressed because it is too large Load Diff