Financial-Times / n-test

A CLI tool and module for lightweight testing of web applications in browsers, designed for FT.com
4 stars 2 forks source link

Fix conflicting workspaces in publish job #191

Closed ivomurrell closed 2 years ago

ivomurrell commented 2 years ago

In theory, we want to make sure that the CircleCI tests have passed before we publish the package to npm. Unfortunately, requiring a job as a dependency of another job implicitly tells the dependent job to use the dependency's workspace layer. If we want to wait on both Node 14 and Node 16 tests to pass before starting the publish job, we also need to attach to both of their workspace layers, causing a conflict seeing as they install different build artefacts. There doesn't seem to be any way to explicitly specify which workspace layers you want a job to attach to, so we instead have to not require the Node 14 tests to pass before the package is published. This is less than ideal but there doesn't seem to be any way around this.

Also update the .nvmrc file, which the latest upgrade-node script supports.