Skip to content

Commit 32923e7

Browse files
Switch to yarn from npm
1 parent cae93dd commit 32923e7

File tree

6 files changed

+35
-57964
lines changed

6 files changed

+35
-57964
lines changed

.github/workflows/ci.yml

+12-13
Original file line numberDiff line numberDiff line change
@@ -8,23 +8,22 @@ jobs:
88
runs-on: ubuntu-latest
99

1010
steps:
11-
- uses: actions/checkout@v2
11+
- uses: actions/checkout@v2.4.0
1212

1313
- name: Set up Node
14-
uses: actions/setup-node@v1
14+
uses: actions/setup-node@v2.5.0
1515
with:
1616
node-version: 14.x
1717

1818
- name: Install Node dependencies
1919
run: |
20-
npm config set package-lock false
21-
npm install
22-
20+
yarn install
21+
2322
- name: Lint the source code
24-
run: npm run lint
23+
run: yarn run lint
2524

2625
- name: Run front-end unit tests
27-
run: npm test
26+
run: yarn run test
2827

2928
- name: Update Coveralls
3029
uses: coverallsapp/github-action@master
@@ -35,10 +34,10 @@ jobs:
3534
runs-on: ubuntu-latest
3635

3736
steps:
38-
- uses: actions/checkout@v2
37+
- uses: actions/checkout@v2.4.0
3938

4039
- name: Set up Python
41-
uses: actions/setup-python@v1
40+
uses: actions/setup-python@v2.3.1
4241
with:
4342
python-version: 3.6
4443

@@ -48,14 +47,14 @@ jobs:
4847
pip install tox
4948
5049
- name: Set up Node
51-
uses: actions/setup-node@v1
50+
uses: actions/setup-node@v2.5.0
5251
with:
53-
node-version: 10.x
52+
node-version: 14.x
5453

5554
- name: Install Node dependencies
5655
run: |
57-
npm config set package-lock false
58-
56+
yarn install
57+
5958
- name: Run back-end tests
6059
run: |
6160
tox

.github/workflows/release.yml

+8-9
Original file line numberDiff line numberDiff line change
@@ -1,27 +1,26 @@
1-
name: Publish
1+
name: Publish
22

3-
on:
3+
on:
44
release:
55
types: [published]
66

77
jobs:
88
release:
99
runs-on: ubuntu-latest
1010
steps:
11-
- uses: actions/checkout@v1
11+
- uses: actions/checkout@v2.4.0
1212

1313
- name: Set up Node
14-
uses: actions/setup-node@v1
14+
uses: actions/setup-node@v2.5.0
1515
with:
1616
node-version: 14.x
1717

1818
- name: Install Node dependencies
1919
run: |
20-
npm config set package-lock false
21-
npm install
20+
yarn install
2221
2322
- name: Set up Python
24-
uses: actions/setup-python@v1
23+
uses: actions/setup-python@v2.3.1
2524
with:
2625
python-version: 3.6
2726

@@ -32,12 +31,12 @@ jobs:
3231
id: build
3332
run: |
3433
python setup.py bdist_wheel
35-
# Get the name of the .whl file and set them as
34+
# Get the name of the .whl file and set them as
3635
# "outputs" of this step so we can upload them
3736
echo "::set-output name=bdist_wheel::$(cd dist && ls *.whl)"
3837
3938
- name: Upload the wheel
40-
uses: actions/upload-release-asset@v1
39+
uses: actions/upload-release-asset@v1.0.2
4140
env:
4241
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
4342
with:

README.md

+10-10
Original file line numberDiff line numberDiff line change
@@ -5,8 +5,8 @@ This application allows consumers to search complaints submitted to the CFPB by
55

66
#### Technology Stack
77
This application is written in JavaScript and [Less](http://lesscss.org) within
8-
the [React](https://facebook.github.io/react/) + [Redux](http://redux.js.org/)
9-
framework. It uses [Webpack](http://webpack.github.io/docs/) at runtime to
8+
the [React](https://facebook.github.io/react/) + [Redux](http://redux.js.org/)
9+
framework. It uses [Webpack](http://webpack.github.io/docs/) at runtime to
1010
manage module loading.
1111

1212
The code is written with the [ES6](http://es6-features.org/) feature set
@@ -17,7 +17,7 @@ Unit testing of the application is performed within
1717
[Jest](https://facebook.github.io/jest/) with
1818
[Enzyme](http://airbnb.io/enzyme/index.html) providing support for event testing.
1919

20-
[npm](https://www.npmjs.com/) is used to manage the build/test/deploy cycle.
20+
[yarn](https://yarnpkg.com/) is used to manage the build/test/deploy cycle.
2121

2222
The `ccdb5_ui` (note the underscore) directory contains a thin [Django](https://www.djangoproject.com/)
2323
implementation that allows it to be used as a plugin for
@@ -66,7 +66,7 @@ For local development, you will need to the following:
6666
To run the app in development mode:
6767

6868
```bash
69-
npm start
69+
yarn run start
7070
```
7171

7272
Open http://localhost:3000 to view it in the browser.
@@ -82,7 +82,7 @@ Enter `Control-C` to exit development mode
8282
To launch the JavaScript test runner in interactive watch/test mode:
8383

8484
```bash
85-
npm test
85+
yarn run test
8686
```
8787

8888
Enter `Control-C` to exit interactive watch mode
@@ -96,11 +96,11 @@ tox
9696

9797
## Cypress integration tests
9898

99-
Our browser-based tests check base-line user operations for [consumer complaint search](https://www.consumerfinance.gov/data-research/consumer-complaints/search/). The tests are meant to be run
100-
against a consumerfinance.gov website that has access to an Elasticsearch index of consumer complaints.
99+
Our browser-based tests check base-line user operations for [consumer complaint search](https://www.consumerfinance.gov/data-research/consumer-complaints/search/). The tests are meant to be run
100+
against a consumerfinance.gov website that has access to an Elasticsearch index of consumer complaints.
101101
Tests can be run in a local environment, or they can be run against an external server.
102102

103-
Using a Chrome browser helps avoid some inconsistencies with Cypress's default Electron browser, which currently isn't on the latest
103+
Using a Chrome browser helps avoid some inconsistencies with Cypress's default Electron browser, which currently isn't on the latest
104104
version of Chrome.
105105

106106
Timeouts and the local `baseUrl` are set in cypress.json
@@ -132,9 +132,9 @@ yarn run cypress open --browser chrome
132132
```
133133

134134
### To run against a server
135-
You can also run Cypress tests against a server by passing a `baseUrl` config with the path to the server's consumer complaints search page.
135+
You can also run Cypress tests against a server by passing a `baseUrl` config with the path to the server's consumer complaints search page.
136136

137-
**Note**: If you run against a server that has Django's `DEBUG=False` setting, the tests will probably run into API throttling, which will make tests fail.
137+
**Note**: If you run against a server that has Django's `DEBUG=False` setting, the tests will probably run into API throttling, which will make tests fail.
138138
Our internal DEV servers can be deployed with `DEBUG=True` for running Cypress tests.
139139

140140
```bash

config/webpack.config.dev.js

+3-3
Original file line numberDiff line numberDiff line change
@@ -243,9 +243,9 @@ module.exports = {
243243
// a plugin that prints an error when you attempt to do this.
244244
// See https://github.com/facebookincubator/create-react-app/issues/240
245245
new CaseSensitivePathsPlugin(),
246-
// If you require a missing module and then `npm install` it, you still have
247-
// to restart the development server for Webpack to discover it. This plugin
248-
// makes the discovery automatic so you don't have to restart.
246+
// If you require a missing module and then `yarn install` it, you still
247+
// have to restart the development server for Webpack to discover it.
248+
// This plugin makes the discovery automatic so you don't have to restart.
249249
// See https://github.com/facebookincubator/create-react-app/issues/186
250250
new WatchMissingNodeModulesPlugin(paths.appNodeModules),
251251
// Moment.js is an extremely popular library that bundles large locale files

frontendbuild.sh

+2-2
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
11
set -ev
22

3-
npm install
4-
npm run build
3+
yarn install
4+
yarn run build

0 commit comments

Comments
 (0)