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 Unit Tests #10

Open
jeltedeproft opened this issue Oct 8, 2019 · 12 comments
Open

Add Unit Tests #10

jeltedeproft opened this issue Oct 8, 2019 · 12 comments
Labels
enhancement New feature or request good first issue Good for newcomers Hacktoberfest help wanted Extra attention is needed

Comments

@jeltedeproft
Copy link
Owner

In order to smooth out future development, Unit Tests will become a necessity.
At the moment we barely have any.

@jeltedeproft jeltedeproft added enhancement New feature or request help wanted Extra attention is needed good first issue Good for newcomers Hacktoberfest labels Oct 8, 2019
@NyorJa
Copy link
Contributor

NyorJa commented Oct 10, 2019

what unit test framework are we gonna use? is it mockito? if yes then I am happy to take this

@jeltedeproft
Copy link
Owner Author

@NyorJa no decision on that yet, more than happy to use Mockito. Can we combine that with Junit? I'll add the Mockito dependency to the Gradle build file.

@NyorJa
Copy link
Contributor

NyorJa commented Oct 10, 2019 via email

@jeltedeproft
Copy link
Owner Author

jeltedeproft commented Oct 10, 2019

@NyorJa sorry for the late reply, up to you, whatever you think is most fun, eventually all of them kinda need tests. I guess the Screen package is the most important one, but also very graphic so maybe hard to test.

I tried adding the Mockito dependency, but when I then tested with a random Mockito class, It said that it couldnt find the import :/ idk what im doing wrong

@jeltedeproft
Copy link
Owner Author

@NyorJa Mockito should now be working, I was confused because I added a class to test if the import works, but I used testCompile in gradle build file, so it doesn't work unless its in the test package.

@jeltedeproft
Copy link
Owner Author

@NyorJa hey, The Mockito is working now, qre you still interested in adding Unit Tests?

@NyorJa
Copy link
Contributor

NyorJa commented Oct 14, 2019 via email

@jeltedeproft
Copy link
Owner Author

@NyorJa ah I'm sorry. If something needs clarification, I'm here :)

@alvin-muniz
Copy link

Hi! I am eager to help with this project. I'm learning JUnit and think this would be a great opportunity for me to get some experience.

Are you available if I have any questions on how to set up some of the tests?

@jeltedeproft
Copy link
Owner Author

@alvin-muniz Hey Alvin, yeah sure , you can always email me at jeltedeproft_8@hormail.com
Or you can join our discord.

I have to admit , since starting my new job I am way less active in developing, but I am definitely available to answer your questions.

@NyorJa
Copy link
Contributor

NyorJa commented Mar 3, 2020

Hi @jeltedeproft,

Please see my pull request. Its an example of unit test for Mockito. I know there are other better framework in unit testing in Android. I also arrange the packages.

@jeltedeproft
Copy link
Owner Author

@alvin-muniz merged it 👍

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request good first issue Good for newcomers Hacktoberfest help wanted Extra attention is needed
Projects
None yet
Development

No branches or pull requests

3 participants