Skip to content

Commit b0f4a74

Browse files
committed
Add query check to circle ci
Dogfoods apollo queries:check
1 parent 23abc81 commit b0f4a74

1 file changed

Lines changed: 24 additions & 0 deletions

File tree

.circleci/config.yml

Lines changed: 24 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -59,6 +59,28 @@ jobs:
5959
- run: npm install --ignore-scripts
6060
- run: npm run lint
6161

62+
Query Check:
63+
docker: [{ image: "circleci/node:8" }]
64+
steps:
65+
- *run_install_desired_npm
66+
- checkout
67+
- restore_cache:
68+
keys:
69+
# When lock file changes, use increasingly general patterns to restore cache
70+
- npm-v1-{{ .Branch }}-{{ checksum "package-lock.json" }}
71+
- npm-v1-{{ .Branch }}-
72+
- npm-v1-
73+
- run: npm --version
74+
- run: npm install
75+
- run: packages/apollo-cli/bin/run queries:check --queries="packags/apollo-cli/src/operations/*" --key=$STAGING_API_KEY --engine=https://engine-staging-graphql.apollographql.com/api/graphql
76+
- save_cache:
77+
key: npm-v1-{{ .Branch }}-{{ checksum "package-lock.json" }}
78+
paths:
79+
# This should cache the npm cache instead of node_modules, which is needed because
80+
# npm ci actually removes node_modules before installing to guarantee a clean slate.
81+
- ~/.npm
82+
- run: npm run circle
83+
6284
ignore_doc_branches: &ignore_doc_branches
6385
filters:
6486
branches:
@@ -75,3 +97,5 @@ workflows:
7597
<<: *ignore_doc_branches
7698
- Linting:
7799
<<: *ignore_doc_branches
100+
- Query Check:
101+
<<: *ignore_doc_branches

0 commit comments

Comments
 (0)