• Home
  • Features
  • Pricing
  • Docs
  • Announcements
  • Sign In

cjolowicz / muckr-web / 26
100%

Build:
DEFAULT BRANCH: master
Ran 12 Jan 2019 09:44PM UTC
Jobs 1
Files 10
Run time 1s
Badge
Embed ▾
README BADGES
x

If you need to use a raster PNG badge, change the '.svg' to '.png' in the link

Markdown

Textile

RDoc

HTML

Rst

pending completion
26

push

travis-ci-com

cjolowicz
Add test for constants

This test module serves mainly to provide coverage for the ternary
operator in the constants module, which depends on an environment
variable.

Some implementation notes:

 - We use `require`, because we need to import the module after
   setting the process environment. Appease eslint by disabling the
   `global-require` rule.

 - `process.env` needs to be set in the `it` block, not in the
   `describe` block, to avoid a race with `require`.

 - We need to reset the module cache before each `require`. This can
   be done using `jest.resetModules` instead of a manual `delete
   require.cache[require.resolve(module)]`.

 - We reset `process.env` after each test, to avoid leakage into other
   tests.

Closes: #9

23 of 23 branches covered (100.0%)

Branch coverage included in aggregate %.

70 of 70 relevant lines covered (100.0%)

7.67 hits per line

Jobs
ID Job ID Ran Files Coverage
1 26.1 12 Jan 2019 09:44PM UTC 0
100.0
Travis Job 26.1
Source Files on build 26
Detailed source file information is not available for this build.
  • Back to Repo
  • Build #26
  • e8bfee46 on github
  • Prev Build on master (#24)
  • Next Build on master (#26)
STATUS · Troubleshooting · Open an Issue · Sales · Support · CAREERS · ENTERPRISE · START FREE · SCHEDULE DEMO
ANNOUNCEMENTS · TWITTER · TOS & SLA · Supported CI Services · What's a CI service? · Automated Testing

© 2026 Coveralls, Inc