-
-
Notifications
You must be signed in to change notification settings - Fork 263
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
Migrate keypress tests to use keys_for_command #469
Comments
@zulipbot claim |
The previous keypress tests used hardcoded tests against specific keys. This could have potentially broken tests if any keybinding would have updated. Updated keypress tests to use `keys_for_command` to ensure the tests are future-proof and they work for multiple specified keys. Fixes zulip#469.
The previous keypress tests used hardcoded tests against specific keys. This could have potentially broken tests if any keybinding would have updated. Updated keypress tests to use `keys_for_command` to ensure the tests are future-proof and they work for multiple specified keys. Fixes zulip#469.
The previous keypress tests used hardcoded tests against specific keys. This could have potentially broken tests if any keybinding would have updated. Updated keypress tests to use `keys_for_command` to ensure the tests are future-proof and they work for multiple specified keys. Fixes zulip#469.
The previous keypress tests used hardcoded tests against specific keys. This could have potentially broken tests if any keybinding would have updated. Updated keypress tests to use `keys_for_command` to ensure that the tests are future-proof and they work for multiple specified keys. Fixes zulip#469.
The previous keypress tests used hardcoded tests against specific keys. This could have potentially broken tests if any keybinding would have updated. Updated keypress tests to use `keys_for_command` to ensure that the tests are future-proof and they work for multiple specified keys. Fixes zulip#469.
The previous keypress tests used hardcoded tests against specific keys. This could have potentially broken tests if any keybinding would have updated. Updated keypress tests to use `keys_for_command` to ensure that the tests are future-proof and they work for multiple specified keys. Fixes zulip#469.
The previous keypress tests used hardcoded tests against specific keys. This could have potentially broken tests if any keybinding would have updated. Updated trivial keypress tests to use `keys_for_command` to ensure that the tests are future-proof and they work for multiple specified keys. Fixes zulip#469.
The previous keypress tests used hardcoded tests against specific keys. This could have potentially broken tests if any keybinding would have updated. Updated trivial keypress tests to use `keys_for_command` to ensure that the tests are future-proof and they work for multiple specified keys. Fixes zulip#469.
Thanks to the work of @preetmishra in #523 this issue has been partially resolved 👍 |
Hello @preetmishra, you have been unassigned from this issue because you have not updated this issue or any referenced pull requests for over 14 days. You can reclaim this issue or claim any other issue by commenting Thanks for your contributions, and hope to see you again soon! |
@neiljp any particular reason why it's still partially resolved? |
I'm not entirely sure originally why this was left open. However, there are still explicit checks and/or calls to keypress with specific characters - that's not necessarily test-specific, though things (including tests) may break if we customized the keys. |
Right. There are few instances of hard-coded keys that are not specific to tests, do you want me to fix those? |
Generally we want all the keys to be flexible to allow for customization, so explicitly calling with particular keys is quite likely to break at some point. A separate PR is fine - it can often be quicker and easier to review, as long as it's straightforward. If there is another commit then they all need to be considered. |
This commit replaces all instances of hard-coded keys passed to keypress that posed a risk of breaking tests if in future we tried to customize the keys. Instead of passing keys we pass their corresponding commands that is more flexible and resistant to breakage on changing keys. Fixes zulip#469.
This commit replaces all instances of hard-coded keys passed to keypress that posed a risk of breaking tests if in future we tried to customize the keys. Instead of passing keys we pass their corresponding commands that is more flexible and resistant to breakage on changing keys. Tests amended. Fixes zulip#469.
This commit replaces all instances of hard-coded keys passed to keypress that posed a risk of breaking tests if in future we tried to customize the keys. Instead of passing keys we pass their corresponding commands that is more flexible and resistant to breakage on changing keys. Tests amended. Fixes zulip#469.
This commit replaces all instances of hard-coded keys passed to keypress that posed a risk of breaking tests if in future we tried to customize the keys. Instead of passing keys we pass their corresponding commands that is more flexible and resistant to breakage on changing keys. Tests amended. Fixes zulip#469.
This commit replaces all instances of hard-coded keys passed to keypress that posed a risk of breaking tests if in future we tried to customize the keys. Instead of passing keys we pass their corresponding commands that is more flexible and resistant to breakage on changing keys. Tests amended. Fixes zulip#469.
Current keypress tests use hardcoded tests against specific keys. It would seem cleaner to use
keys_for_command
to both ensure this works for multiple specified keys, and also to automatically update if the standard keys are updated inconfig/keys.py
.This might be able to be simplified by writing an appropriate parametrized fixture.
The text was updated successfully, but these errors were encountered: