Skip to content

refactor test suite

  • create a harness file for test suite where chai is configured
  • move mocha configuration to test/config.js file
  • set NODE_ENV environment variable to "test" in test suite
  • rename test files to have -test.js extension
  • increase test timeout to 10 minutes and remove override in integration test
  • forbid the use of only in CI
  • silence logging in test suite
  • move docs site fixture to fixtures folder
  • generate docs into work directory and cleanup after tests are complete
  • consolidate npm scripts to test, coverage, and lint
  • configure nyc
  • generate lcov report and output location when tests complete successfully
  • save lcov report as a CI artifact
  • move coverage report to coverage-report folder
  • move test report to test-report folder
  • make git ignore files more specific
  • use fs.promises for file operations
  • use ospath as variable for platform-specific path function
  • put empty line between each test in test suite

Merge request reports