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 widgets tests #118

Open
stsewd opened this issue Nov 21, 2020 · 0 comments
Open

Improve widgets tests #118

stsewd opened this issue Nov 21, 2020 · 0 comments
Labels
enhancement New feature or request good first issue Good for newcomers

Comments

@stsewd
Copy link
Member

stsewd commented Nov 21, 2020

In some places where we need to pass a callback

button = Button("Exit", handler=lambda: print("Hi"))

ListElement("One", on_select=lambda: print("Select")),
ListElement("Two"),
ListElement("Three", on_focus=lambda: print("Focus")),

We should actually pass a mock and assert that the mock has been called when expected.

@stsewd stsewd added enhancement New feature or request good first issue Good for newcomers labels Nov 21, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request good first issue Good for newcomers
Projects
None yet
Development

No branches or pull requests

1 participant