Skip to content

Commit 9f1dd39

Browse files
committed
ci(Travis): Add flowtype and eslint for build tests
1 parent 313e196 commit 9f1dd39

File tree

4 files changed

+14
-13
lines changed

4 files changed

+14
-13
lines changed

.travis.yml

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,8 +12,11 @@ node_js:
1212
- "6"
1313
- "5"
1414
- "4"
15+
before_install: yarn global add greenkeeper-lockfile@1
16+
before_script: greenkeeper-lockfile-update
17+
after_script: greenkeeper-lockfile-upload
1518
script:
16-
- yarn run coverage -- --maxWorkers 4
19+
- yarn run test
1720
- yarn run build
1821
after_success:
1922
- 'curl -Lo travis_after_all.py https://git.io/travis_after_all'

README.md

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,13 +1,12 @@
11
# graphql-compose-mongoose
22

3-
[![Greenkeeper badge](https://badges.greenkeeper.io/nodkz/graphql-compose-mongoose.svg)](https://greenkeeper.io/)
4-
53
[![travis build](https://img.shields.io/travis/nodkz/graphql-compose-mongoose.svg)](https://travis-ci.org/nodkz/graphql-compose-mongoose)
64
[![codecov coverage](https://img.shields.io/codecov/c/github/nodkz/graphql-compose-mongoose.svg)](https://codecov.io/github/nodkz/graphql-compose-mongoose)
75
[![](https://img.shields.io/npm/v/graphql-compose-mongoose.svg)](https://www.npmjs.com/package/graphql-compose-mongoose)
86
[![npm](https://img.shields.io/npm/dt/graphql-compose-mongoose.svg)](http://www.npmtrends.com/graphql-compose-mongoose)
97
[![Join the chat at https://gitter.im/graphql-compose/Lobby](https://badges.gitter.im/nodkz/graphql-compose.svg)](https://gitter.im/graphql-compose/Lobby)
108
[![Commitizen friendly](https://img.shields.io/badge/commitizen-friendly-brightgreen.svg)](http://commitizen.github.io/cz-cli/)
9+
[![Greenkeeper badge](https://badges.greenkeeper.io/nodkz/graphql-compose-mongoose.svg)](https://greenkeeper.io/)
1110

1211

1312
This is a plugin for [graphql-compose](https://github.com/nodkz/graphql-compose), which derives GraphQLType from your [mongoose model](https://github.com/Automattic/mongoose). Also derives bunch of internal GraphQL Types. Provide all CRUD resolvers, including `graphql connection`, also provided basic search via operators ($lt, $gt and so on).

package.json

Lines changed: 4 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -48,7 +48,7 @@
4848
"eslint-plugin-prettier": "^2.1.1",
4949
"flow-bin": "^0.47.0",
5050
"graphql": "^0.10.1",
51-
"graphql-compose": "^1.20.4",
51+
"graphql-compose": "^1.21.1",
5252
"graphql-compose-connection": "^2.2.1",
5353
"jest": "^20.0.4",
5454
"mongodb-memory-server": "^1.3.4",
@@ -71,12 +71,11 @@
7171
"build": "npm run build-cjs && npm run build-flow",
7272
"build-cjs": "rimraf lib && babel src --ignore __tests__,__mocks__ -d lib",
7373
"build-flow": "find ./src -name '*.js' -not -path '*/__*' | while read filepath; do cp $filepath `echo $filepath | sed 's/\\/src\\//\\/lib\\//g'`.flow; done",
74-
"coverage": "jest --coverage",
75-
"lint": "eslint src test *.js",
76-
"test": "jest",
7774
"watch": "jest --watch",
75+
"coverage": "jest --coverage --maxWorkers 2",
76+
"lint": "eslint --ext .js ./src",
7877
"flow": "./node_modules/.bin/flow stop && ./node_modules/.bin/flow",
79-
"all": "npm run test && npm run lint && npm run flow",
78+
"test": "npm run coverage && npm run lint && npm run flow",
8079
"link": "yarn build && yarn link graphql-compose && yarn link graphql-compose-connection && yarn link mongoose && yarn link",
8180
"unlink": "yarn unlink graphql-compose && yarn unlink graphql-compose-connection && yarn unlink mongoose && yarn add graphql-compose graphql-compose-connection mongoose --dev",
8281
"semantic-release": "semantic-release pre && npm publish && semantic-release post"

yarn.lock

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1895,7 +1895,7 @@ glob-parent@^2.0.0:
18951895
dependencies:
18961896
is-glob "^2.0.0"
18971897

1898-
glob@^7.0.0, glob@^7.0.3, glob@^7.0.5:
1898+
glob@^7.0.0, glob@^7.0.3:
18991899
version "7.1.1"
19001900
resolved "https://registry.yarnpkg.com/glob/-/glob-7.1.1.tgz#805211df04faaf1c63a3600306cdf5ade50b2ec8"
19011901
dependencies:
@@ -1906,7 +1906,7 @@ glob@^7.0.0, glob@^7.0.3, glob@^7.0.5:
19061906
once "^1.3.0"
19071907
path-is-absolute "^1.0.0"
19081908

1909-
glob@^7.1.1, glob@^7.1.2:
1909+
glob@^7.0.5, glob@^7.1.1, glob@^7.1.2:
19101910
version "7.1.2"
19111911
resolved "https://registry.yarnpkg.com/glob/-/glob-7.1.2.tgz#c19c9df9a028702d678612384a6552404c636d15"
19121912
dependencies:
@@ -1946,9 +1946,9 @@ graphql-compose-connection@^2.2.1:
19461946
dependencies:
19471947
babel-runtime "^6.23.0"
19481948

1949-
graphql-compose@^1.20.4:
1950-
version "1.20.4"
1951-
resolved "https://registry.yarnpkg.com/graphql-compose/-/graphql-compose-1.20.4.tgz#de70282439b29e2014fae0ee6effca6fbd348b9e"
1949+
graphql-compose@^1.21.1:
1950+
version "1.21.1"
1951+
resolved "https://registry.yarnpkg.com/graphql-compose/-/graphql-compose-1.21.1.tgz#65a8152335285d51d1d220ba3355b7e4eb52a515"
19521952
dependencies:
19531953
babel-runtime "^6.23.0"
19541954
object-path "^0.11.4"

0 commit comments

Comments
 (0)