Sign inSign up

adiii717/jest

By adiii717

Updated almost 7 years ago

This image include latest npm, nodejs ,jest and npx

Image
0

416

adiii717/jest repository overview

Dockerfile

FROM node:alpine
RUN apk add --no-cache git
RUN npm install jest npx -g
WORKDIR /app
RUN git clone https://github.com/valentinogagliardi/getting-started-with-jest.git /app
RUN npm install
RUN Test
docker run -ti adiii717/jest npx jest

output:

$ docker run -ti adiii717/jest npx jest
 PASS  __tests__/filterByTerm.spec.js
  Filter function
    ✓ it should filter by a search term (link) (4ms)
    ✓ it should filter by a search term (uRl)
    ✓ it should throw when searchTerm is empty string (3ms)

-----------------|----------|----------|----------|----------|-------------------|
File             |  % Stmts | % Branch |  % Funcs |  % Lines | Uncovered Line #s |
-----------------|----------|----------|----------|----------|-------------------|
All files        |     87.5 |       75 |      100 |      100 |                   |
 filterByTerm.js |     87.5 |       75 |      100 |      100 |                 3 |
-----------------|----------|----------|----------|----------|-------------------|
Test Suites: 1 passed, 1 total
Tests:       3 passed, 3 total
Snapshots:   0 total
Time:        1.192s
Ran all test suites.
with filter
docker run -ti adiii717/jest sh -c 'npx jest -t "it should filter by a search term (link)"'

output

docker run -ti adiii717/jest sh -c 'npx jest -t "it should filter by a search term (link)"'
-----------------|----------|----------|----------|----------|-------------------|
File             |  % Stmts | % Branch |  % Funcs |  % Lines | Uncovered Line #s |
-----------------|----------|----------|----------|----------|-------------------|
All files        |     12.5 |        0 |        0 |    16.67 |                   |
 filterByTerm.js |     12.5 |        0 |        0 |    16.67 |         2,3,4,5,6 |
-----------------|----------|----------|----------|----------|-------------------|
Test Suites: 1 skipped, 0 of 1 total
Tests:       3 skipped, 3 total
Snapshots:   0 total
Time:        1.109s
Ran all test suites with tests matching "it should filter by a search term (link)".

Tag summary

Content type

Image

Digest

Size

76.7 MB

Last updated

almost 7 years ago

docker pull adiii717/jest