sopel-irc / sopel-remind

Other
0 stars 1 forks source link

plugin: minor grammar tweak #7

Closed dgw closed 1 year ago

dgw commented 1 year ago

Mmm, tests that check hard-coded strings. Goodbye, "Verified" commit badge from making a quick one-file edit on GH. 😂

I should mention that my local make test against an installed sopel at 8.0.0.dev0 (upstream commit sopel-irc/sopel@79b6bce73f4de083a5019443a1cc45896c3ec7f5) fails on bot.connection_registered-related stuff:

___________________________________________________ ERROR at setup of test_job_connected_but_not_registered ____________________________________________________
tests/test_integration.py:43: in irc
    server.bot.connection_registered = True
E   AttributeError: can't set attribute
---------------------------------------------------------------------- Captured log setup ----------------------------------------------------------------------
WARNING  sopel.config.types:types.py:540 Using "," as item delimiter in option "enable" is deprecated and will be removed in Sopel 9; use multi-line instead
WARNING  sopel.config.types:types.py:540 Using "," as item delimiter in option "enable" is deprecated and will be removed in Sopel 9; use multi-line instead
=================================================================== short test summary info ====================================================================
ERROR tests/test_integration.py::test_remind_in - AttributeError: can't set attribute
ERROR tests/test_integration.py::test_remind_in_no_argument - AttributeError: can't set attribute
ERROR tests/test_integration.py::test_remind_in_invalid_argument - AttributeError: can't set attribute
ERROR tests/test_integration.py::test_remind_at - AttributeError: can't set attribute
ERROR tests/test_integration.py::test_remind_at_no_argument - AttributeError: can't set attribute
ERROR tests/test_integration.py::test_remind_at_invalid_argument - AttributeError: can't set attribute
ERROR tests/test_integration.py::test_shutdown - AttributeError: can't set attribute
ERROR tests/test_integration.py::test_job_no_reminders - AttributeError: can't set attribute
ERROR tests/test_integration.py::test_job_future_reminders - AttributeError: can't set attribute
ERROR tests/test_integration.py::test_job_past_reminders - AttributeError: can't set attribute
ERROR tests/test_integration.py::test_job_not_connected - AttributeError: can't set attribute
ERROR tests/test_integration.py::test_job_connected_but_not_registered - AttributeError: can't set attribute

_Failures other than test_job_connected_but_not_registered have the same file/line and the same captured log setup, so I included only the one for brevity._

This could be the AttributeError @luk3yx mentioned in #4. In the Sopel 8 dev branch, bot.connection_registered is now a property, meaning the test setup code here cannot simply overwrite its value to True. CI works because it's installing the stable package, sopel==7.1.9.

dgw commented 1 year ago

@Exirel gentle nudge 🙂