You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Bug fixing things to do with the importer is tricky as there's a lot of tests that look a lot to me like magic number assertations. For example, this test asserts that there should be 15 events - why?
I think overall we need smaller and more specific unit tests for each stage of the process rather than these monolithic end to end ones.
Motivation
Importer logic is hard to reason about and test values seem arbritrary. This is a good recipe for introducing a lot of magic number bugs, and doesn't help us understand more about the code.
The text was updated successfully, but these errors were encountered:
Description
Bug fixing things to do with the importer is tricky as there's a lot of tests that look a lot to me like magic number assertations. For example, this test asserts that there should be 15 events - why?
PlaceCal/test/jobs/calendar_importer/calendar_importer_task_test.rb
Line 132 in 97c5c25
An example of why this is confusing is that if I remove the
!
here, the event count changes from 15 to 17. I can't meaningfully reason about why.PlaceCal/app/jobs/calendar_importer/parsers/ld_json.rb
Line 116 in 4ea8af5
I think overall we need smaller and more specific unit tests for each stage of the process rather than these monolithic end to end ones.
Motivation
Importer logic is hard to reason about and test values seem arbritrary. This is a good recipe for introducing a lot of magic number bugs, and doesn't help us understand more about the code.
The text was updated successfully, but these errors were encountered: