Skip to content

Commit 610f930

Browse files
authored
Move Gateway compatibility tests to smoke-test (#7085)
Previously, we installed six versions of `@apollo/gateway` via the monorepo package.json, which we used as part of the test suite to check to see if `new ApolloServer({gateway: new ApolloGateway()})` compiled (and ran, but not actually started/served). Some of these versions are quite old and require `--no-engine-strict` to install under Node v18 (because our `.npmrc` sets `engine-strict` to true for some reason). Now that Node v18 is LTS, Renovate wants to start using v18 itself and upgrade us to v18, but it's running into trouble due to these failures. We take the easy way out and move this test to the `smoke-test` directory. Now we don't install these `@apollo/gateway` versions unless we're actively running the smoke test. (This also means we no longer have AS3 in our package-lock.json!) Fixes #7078.
1 parent c9d78c8 commit 610f930

15 files changed

+6580
-9969
lines changed

.changeset/hip-years-repair.md

+2
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
---
2+
---

.circleci/config.yml

+2-20
Original file line numberDiff line numberDiff line change
@@ -28,23 +28,7 @@ commands:
2828
- run: volta pin node@<< parameters.node-version >>
2929
- run: node --version
3030
- run: npm --version
31-
# For now, we ignore `engine` constraints in package.json when running on
32-
# Node 18. That's because we install a bunch of versions of
33-
# @apollo/gateway for compatibility testing, including some from the era
34-
# where we liked putting `<` engine constraints on all our packages. If
35-
# this gets awkward, we can stop testing those old versions, or test them
36-
# somewhere more self-contained like the smoke-test.
37-
- when:
38-
condition:
39-
equal: [ '18', << parameters.node-version >> ]
40-
steps:
41-
- node/install-packages:
42-
override-ci-command: npm ci --no-engine-strict
43-
- unless:
44-
condition:
45-
equal: [ '18', << parameters.node-version >> ]
46-
steps:
47-
- node/install-packages
31+
- node/install-packages
4832

4933

5034
jobs:
@@ -79,9 +63,7 @@ jobs:
7963
node-version: "18"
8064
# Install a prerelease of graphql-js 17 with incremental delivery support.
8165
# --legacy-peer-deps because nothing expects v17 yet.
82-
# --no-engine-strict because Node v18 doesn't match the engines fields
83-
# on some old stuff.
84-
- run: npm i --legacy-peer-deps --no-engine-strict graphql@17.0.0-alpha.1.canary.pr.3361.04ab27334641e170ce0e05bc927b972991953882
66+
- run: npm i --legacy-peer-deps graphql@17.0.0-alpha.1.canary.pr.3361.04ab27334641e170ce0e05bc927b972991953882
8567
- run: npm run test:ci
8668
- run: npm run test:smoke
8769

0 commit comments

Comments
 (0)