New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add CoverageChecker #2273

Merged
merged 1 commit into from Nov 27, 2018

Conversation

Projects
None yet
1 participant
@kevinrobinson
Copy link
Contributor

kevinrobinson commented Nov 27, 2018

Who is this PR for?

developers

What problem does this PR fix?

Enforces test coverage on particularly critical files. This of course is not a great measure of code quality or even test quality, but for these files we have this level of coverage now and this can help us spot gaps if they are introduced.

What does this PR do?

Fails CI if test coverage for particular files is not 100%. It can be run locally with ENABLE_RSPEC_COVERAGE_CHECKER. Also adds some test cases to authorizer.rb and fixes a typo in mentionbot.

Screenshot (if adding a client-side feature)

screen shot 2018-11-27 at 2 39 37 pm

Checklists

Which features or pages does this PR touch?

  • Travis build

Does this PR use tests to help verify we can deploy these changes quickly and confidently?

  • Included specs for changes
  • Improved specs for existing code in need of better test coverage
  • Manual testing made more sense here
@kevinrobinson

This comment has been minimized.

Copy link
Contributor

kevinrobinson commented Nov 27, 2018

From Travis:

Coverage report generated for RSpec to /home/travis/build/studentinsights/studentinsights/coverage. 12901 / 13828 LOC (93.3%) covered.
CoverageChecker: On this run, checked 4 files for full coverage, all passed!
The command "ENABLE_RSPEC_COVERAGE_CHECKER=true bundle exec rspec spec" exited with 0.
@kevinrobinson

This comment has been minimized.

Copy link
Contributor

kevinrobinson commented Nov 27, 2018

selfie

@kevinrobinson kevinrobinson merged commit 9eaa678 into master Nov 27, 2018

1 check passed

continuous-integration/travis-ci/pr The Travis CI build passed
Details

@kevinrobinson kevinrobinson deleted the feature/enforce-full-coverage-split branch Nov 27, 2018

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment