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

Remove network calls from tests #2055

Conversation

michael-genson
Copy link
Collaborator

What type of PR is this?

(REQUIRED)

  • cleanup

What this PR does / why we need it:

(REQUIRED)

One of our scrapers wasn't being mocked, so tests were making network calls. This abstracts the get_html in a predictable way so we can easily mock it, and automatically mock any new scraper strategies down the line.

Which issue(s) this PR fixes:

(REQUIRED)

Mentioned in PR #2050

Testing

(fill-in or delete this section)

Just for sanity I replaced one of the mock URLs with a broken URL and ran the test, which passed.

Release Notes

(REQUIRED)

NONE

@michael-genson
Copy link
Collaborator Author

michael-genson commented Jan 29, 2023

I think the linting issue mentioned in #2044 is failing the frontend tests

@hay-kot hay-kot merged commit 4fc4ba9 into mealie-recipes:mealie-next Feb 5, 2023
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.

2 participants