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

Fix tests and change some objects #262

Merged
merged 5 commits into from
Aug 1, 2024
Merged

Conversation

Lash-L
Copy link
Contributor

@Lash-L Lash-L commented Jul 24, 2024

Changes:

  • Removed async_setup - when configuration setup isn't done in yaml, it doesn't need to exist.
  • Changed to OptionsFlowwithConfigEntry
  • Created two fixtures to get either a mockconfigentry or a mock config entry that has been set up
  • Changed how setup of entries works
  • Instead of directly calling functions in init, we now use hass to call them

I will have to change either this Pr or the other depending on which gets merged first

@agittins
Copy link
Owner

I figured this one might be easier to rebase, so I merged the formatting PR first.

Copy link
Owner

@agittins agittins left a comment

Choose a reason for hiding this comment

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

This is great, thanks! I was pretty baffled with the whole testing thing :-)

custom_components/bermuda/config_flow.py Show resolved Hide resolved
tests/test_config_flow.py Outdated Show resolved Hide resolved
Copy link
Owner

@agittins agittins left a comment

Choose a reason for hiding this comment

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

Awesome!

@agittins agittins merged commit c26d64f into agittins:main Aug 1, 2024
4 checks passed
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