Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

chore(infra): test Node.js v16 and expand "engines" range to include it #713

Merged
merged 14 commits into from
May 3, 2021
Merged
Show file tree
Hide file tree
Changes from 8 commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
46 changes: 36 additions & 10 deletions .circleci/config.yml
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,8 @@ commands:
common_test_steps:
description: "Commands run on each Node.js job (not for Rust jobs)"
steps:
- oss/install_specific_npm_version
- oss/install_specific_npm_version:
version: '7'
- checkout
- oss/npm_clean_install_with_caching
- run:
Expand All @@ -43,7 +44,7 @@ executors:
rust_windows: &rust_windows_executor
machine:
image: 'windows-server-2019-vs2019:stable'
resource_class: windows.medium
resource_class: windows.xlarge
shell: powershell.exe -ExecutionPolicy Bypass

# Important! When adding a new job to `jobs`, make sure to define when it
Expand All @@ -54,7 +55,8 @@ jobs:
# at https://hub.docker.com/r/circleci/node/.

NodeJS 12:
executor: { name: oss/node, tag: '12' }
docker:
- image: cimg/node:12.22.1
steps:
- common_test_steps
# We will save the results of this one particular invocation to use in
Expand All @@ -68,15 +70,24 @@ jobs:
- ./**

NodeJS 14:
executor: { name: oss/node, tag: '14' }
docker:
- image: cimg/node:14.16.1
steps:
- common_test_steps

NodeJS 16:
docker:
- image: cimg/node:16.0.0
steps:
- common_test_steps

GraphQL Types:
description: "Assert generated GraphQL types are up to date"
executor: { name: oss/node, tag: '14' }
docker:
- image: cimg/node:14.16.1
steps:
- oss/install_specific_npm_version
- oss/install_specific_npm_version:
version: '7'
- checkout
- oss/npm_clean_install_with_caching
- run:
Expand All @@ -87,8 +98,11 @@ jobs:
type: executor
executor: << parameters.platform >>
environment:
# Note: This is a no-op at the second, but bear with me on this. If this
# comment is not removed by 2021-06-30 remove it along with the next line.
# renovate: datasource=github-tags depName=nodejs/node versioning=node
NODE_VERSION: 14.16.1
NPM_VERSION: 6.14.13
NPM_VERSION: 7.10.0
steps:
- checkout
- when:
Expand Down Expand Up @@ -172,13 +186,17 @@ jobs:
steps:
- run:
name: Install rustup
environment:
# Override auto-detection of RAM for Rustc install.
# https://github.com/rust-lang/rustup/issues/2229#issuecomment-585855925
RUSTUP_UNPACK_RAM: "21474836480"
command: |
$installer_dir = "$Env:TEMP"
echo "Downloading rustup"
(New-Object System.Net.WebClient).DownloadFile("https://win.rustup.rs", "$installer_dir\rustup-init.exe")
(New-Object System.Net.WebClient).DownloadFile("https://win.rustup.rs/x86_64", "$installer_dir\rustup-init.exe")
echo "Installing rustup"
& $installer_dir\rustup-init.exe --profile minimal --component rustfmt,clippy -y
echo "Done"
exit $LASTEXITCODE
- run:
name: Special case for Windows because of ssh-agent
command: |
Expand Down Expand Up @@ -219,7 +237,10 @@ jobs:
name: Assert npm version
command: |
if ((npm --version) -Ne "${Env:NPM_VERSION}") { exit 1 }
- run: npm clean-install
- run:
name: npm clean-install
command: |
npm clean-install
- rust/test:
# This is prefixed in the orb with 'cargo-'
cache_version: v2-windows
Expand Down Expand Up @@ -264,6 +285,9 @@ workflows:
- NodeJS 14:
name: "JS: Node 14"
<<: *common_non_publish_filters
- NodeJS 16:
name: "JS: Node 16"
<<: *common_non_publish_filters
- GraphQL Types:
name: "GraphQL Types (up to date)"
<<: *common_non_publish_filters
Expand All @@ -281,13 +305,15 @@ workflows:
requires:
- "JS: Node 12"
- "JS: Node 14"
- "JS: Node 16"
- "GraphQL Types (up to date)"
- oss/dry_run:
name: "JS: Dry-run"
<<: *common_publish_filters
requires:
- "JS: Node 12"
- "JS: Node 14"
- "JS: Node 16"
- Rust
- "GraphQL Types (up to date)"
- oss/confirmation:
Expand Down
1 change: 1 addition & 0 deletions .npmrc
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
engine-strict=true
1 change: 1 addition & 0 deletions docs/.npmrc
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
engine-strict=true
1 change: 0 additions & 1 deletion docs/.nvmrc

This file was deleted.

Loading