Skip to content

Instantly share code, notes, and snippets.

@ahmadnassri
Last active July 30, 2020 06:03
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save ahmadnassri/8dd83f3b40aa59dd23e0972b29d1558c to your computer and use it in GitHub Desktop.
Save ahmadnassri/8dd83f3b40aa59dd23e0972b29d1558c to your computer and use it in GitHub Desktop.
node LTS test coverage

requirements

usage

  • create a file called docker-compose.yml in your project directory
  • copy the content from this gist to docker-compose.yml
  • run:
    $ docker-compose run test 
  • commit docker-compose.yml to make it easier for contributors to run tests
version: '3.8'
x-node: &node
tty: true
volumes:
- type: bind
source: .
target: /app
working_dir: /app
command: npm run test
services:
test:
<<: *node
image: node:alpine
depends_on:
- node10
- node12
- node13
- node14
node10:
<<: *node
image: node:10-alpine
node12:
<<: *node
image: node:12-alpine
node13:
<<: *node
image: node:13-alpine
node14:
<<: *node
image: node:14-alpine
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment