-
Notifications
You must be signed in to change notification settings - Fork 26
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
Needs more unit tests #46
Comments
UTSU was built to support the Mockito framework for unit tests. With some exceptions, dependencies are injected through the constructor so that Mockito can easily replace them. That said, I will happily accept unit tests that don't use this framework. |
I've pulled in the latest master branch and am trying to write unit tests against classes from the main java classes. I'm using Netbeans and can't get it to compile any of the unit tests referring to these classes. I presume this is due to exposure of the classes via the modules in the main project. Do you have any example of how this can work, please? |
Sorry for the trouble! I changed around the unit test build structure a few days ago since the way they worked before was hack-y and difficult to extend. Unit testing in the modular world is a bit of a nightmare and IDEs sometimes don't know how to handle the module-info.test files. I use IntelliJ and was able to tell the IDE to build the module-info.test file directly. Regardless of the IDE, you should be able to run tests in the latest master branch by typing "mvn test" in your terminal. Also as of a few days ago the project is using JUnit-Jupiter instead of the older JUnit/Truth libraries I was using before. So the imports would need to be a little different. |
After a suggestion from the maintainer, I'm going to port my existing unit tests to the current codebase.
This may require a few tweaks to some constructors to allow me to create valid SongReader and VoicebankReader objects.
The text was updated successfully, but these errors were encountered: