Skip to content
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

Refactor specs to avoid expecting implementation #34

Draft
wants to merge 20 commits into
base: master
Choose a base branch
from

Conversation

Bodacious
Copy link
Collaborator

What

Refactor the test suite to avoid writing tests that rely on specific implementation details (e.g. method calls).

Why

We want the test suite for these objects to be as robust as possible. The previous implementation was testing that particualr methods were called, rather than testing expected outcomes.

How

Adds RSpec matchers to make better assertions on Prometheus metrics.

Refactor to use new metrics.

Use RSpec built-in helpers where appropriate.

@Bodacious Bodacious changed the base branch from master to gm/queue-time-tracking August 15, 2022 18:38
@Bodacious Bodacious marked this pull request as ready for review August 15, 2022 18:51
Base automatically changed from gm/queue-time-tracking to master August 23, 2022 08:33
@Bodacious Bodacious marked this pull request as draft August 23, 2022 10:52
@Bodacious
Copy link
Collaborator Author

Moved back to draft. I think these changes are too much for one PR, and will split it into smaller parts.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant