Skip to content

Written unit tests for interval comparison#17

Open
greneus wants to merge 10 commits intoUCL-COMP0233-2022-2023:mainfrom
greneus:main
Open

Written unit tests for interval comparison#17
greneus wants to merge 10 commits intoUCL-COMP0233-2022-2023:mainfrom
greneus:main

Conversation

@greneus
Copy link

@greneus greneus commented Nov 2, 2022

Answers UCL-MPHY0021-21-22/RSE-Classwork#16

There is a subtlety in the interval comparison, namely that an interval of 0 seconds (ie. start == end) is also counted as an overlap.

@greneus
Copy link
Author

greneus commented Nov 3, 2022

Answers UCL-MPHY0021-21-22/RSE-Classwork#16

The code is buggy with negative length intervals showing up in results and it's not robust against zero length intervals (ie. when two intervals share edges) -- hence my unit tests fail.

@greneus
Copy link
Author

greneus commented Nov 3, 2022

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.

1 participant