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

Improve republishing worker test coverage #8998

Merged
merged 4 commits into from Apr 29, 2024

Conversation

yndajas
Copy link
Member

@yndajas yndajas commented Apr 25, 2024

There was very little test coverage for the PublishingApiDocumentRepublishingWorker class. I wanted to refactor it quite a bit in order to support an extension needed for a later piece of work. These tests help provide confidence that nothing will break in the later refactor

This was done as groundwork for #8993 (Trello)


⚠️ This repo is Continuously Deployed: make sure you follow the guidance ⚠️

Follow these steps if you are doing a Rails upgrade.

This isn't used in the class and can't be used outside of it
These will be extended in a separate commit
This is a start at adding good test coverage for this class. I haven't
covered the `bulk_republishing: true` conditions here. These tests also
don't verify that the actions happen in the correct order - I'm not sure
if there's an easy way to do that
There's an `:attr_reader` method so this is not needed
@yndajas yndajas force-pushed the improve-republishing-worker-test-coverage branch from b9bedba to 097e631 Compare April 25, 2024 12:26
Copy link
Member

@brucebolt brucebolt left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good, nice idea to increase the test coverage here.

@JonathanHallam JonathanHallam merged commit 39df09d into main Apr 29, 2024
23 checks passed
@JonathanHallam JonathanHallam deleted the improve-republishing-worker-test-coverage branch April 29, 2024 14:27
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.

None yet

4 participants