Skip to content

Add minimal tests #22

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

Closed
leotrs opened this issue May 20, 2020 · 4 comments · Fixed by #28
Closed

Add minimal tests #22

leotrs opened this issue May 20, 2020 · 4 comments · Fixed by #28
Assignees
Labels
enhancement Additions and improvements in general testing Anything related to testing the library

Comments

@leotrs
Copy link
Contributor

leotrs commented May 20, 2020

Before starting any major changes (including high priority ones such as #6), we need a way of testing that our changes do not break the basic functionality of the library. Simply put, I'm afraid to move or touch some files as it is unclear to me whether something will break.

For this, I suggest we start with minimal tests that consist in compiling a handful of scenes, put them in a new file called test/test_example_scenes.py, and we run the test by manually running manim over them. If the scenes look the way they should, then we are good to go. These scenes can be the ones that currently live in sample_scenes.py, for example.

Of course, this is no replacement for a full testing framework, but it should at least be a minimal guarantee that our coming changes are not completely screwing up the library.

@eulertour
Copy link
Member

Simply put, I'm afraid to move or touch some files as it is unclear to me whether something will break.

Manim has never had any tests and is pretty much always broken. That's just the way we've been doing it so far. Not to say that it makes any sense at all, but if the code sort of looks reasonable to you it's already up to the current manim standard, so you shouldn't feel too scared to change it.

That said those tests would be a big help.

@huguesdevimeux huguesdevimeux self-assigned this May 20, 2020
@huguesdevimeux
Copy link
Member

That's a great idea. I take care of that

@huguesdevimeux huguesdevimeux linked a pull request May 20, 2020 that will close this issue
@leotrs leotrs added this to the Initial Cleanup milestone May 20, 2020
@PgBiel PgBiel added enhancement Additions and improvements in general testing Anything related to testing the library labels May 20, 2020
@leotrs leotrs mentioned this issue May 20, 2020
@eulertour
Copy link
Member

#28 doesn't improve the testing situation over running the example scenes manually. The goal is to write a suite which can be run in pytest, nose2, or the like in order to ensure basic functionality.

@eulertour eulertour reopened this May 20, 2020
@leotrs
Copy link
Contributor Author

leotrs commented May 27, 2020

As per #86, there is now a (very very minimal) set of tests in place with pytest. I will close this in favor of all the other issues already mentioning tests.

@leotrs leotrs closed this as completed May 27, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement Additions and improvements in general testing Anything related to testing the library
Projects
None yet
Development

Successfully merging a pull request may close this issue.

4 participants