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

Add two tests #4

Open
wants to merge 4 commits into
base: adding_gjk
Choose a base branch
from
Open

Conversation

Yiqing-Gu
Copy link

Add two test for convex Hull and end point property.

Add two test for convex Hull and end point property.
@magicbycalvin
Copy link
Member

  1. Please move the tests out of the Examples directory and move them all into the Tests directory.
  2. The convex hull test is checking whether something is equal to itself. That will need to change. You should randomly sample several points along a polynomial and then check that each of those points falls within the convex hull. If they all do, then you can say the tests passes.
  3. I'd like to see more randomness included in the testing. While deterministic tests are good, you should also include randomness so that we can explore edge cases that we may have forgotten about as well.
  4. Use different values for initial times as well. The times shouldn't affect anything, but it's good to test and make sure that they don't.

Copy link
Author

@Yiqing-Gu Yiqing-Gu left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

  • Test files were moved to test directory
  • New tests for convex hull
  • Added more randomness into both tests
  • Added different values in initial times
  • Test files were unified into one file for each test
  • Timing test needs to be debug, it will be online later.

-Added timing function for two test. Uncomment to activate it.
Adding reference and tutorial for timeout function.
@magicbycalvin
Copy link
Member

  1. Please also include random end points in the end points test.
  2. Tests shouldn't have to be commented/uncommented, please make sure that all tests will run without the user needing to interact with the code directly. Assume that the user will not ever open the files with the test code, rather they will simply run pytest to verify that changes they make do not break the library.
  3. We don't want a timeout for timing tests, I would like to see an output that shows how long the process took. If that doesn't fit within the pytest framework, that is fine. We can simply add a timing_analysis example in the examples folder.

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.

2 participants