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

initial revision junit test NRUnits #28

Open
wants to merge 1 commit into
base: main
Choose a base branch
from
Open

Conversation

arickard
Copy link

No description provided.

@arickard
Copy link
Author

Just want to demonstrate what a simple JUnit Test might look like for this project. The following tests all the static methods for very simple utility class: NRUnits. This will be run during the test phase of your gradle build and if a test would have failed it will indicate which test failed and not continue to the next phase of the build: deployment. If all test pass it would move on to the deployment phase of the build.

JUnit tests can get much more sophisticated. With the ability to initialize and tear down code before/after a test method is run. This allows one to setup the test before the tests method are run. More sophisticated tests can be build that "mock" subsystems without the need to actually instantiate them and use the mock to test the expected behavior with those mocked subsystems.

Unit test form the basis for any test automation for a software project. There are other levels of test automation that attempt to test software in different ways. For instance integration testing is another common way to test a software system from the "outside" with all running subsystems running together.

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