Skip to content
master
Switch branches/tags
Go to file
Code

Latest commit

 

Git stats

Files

Permalink
Failed to load latest commit information.
Type
Name
Latest commit message
Commit time
src
 
 
 
 
 
 
 
 
 
 

ExampleUnitTests

This is the source code for the tutorial about writing good unit-test suites.

Tutorial

See the tutorial here:

http://smartpuffin.com/unit-tests-tutorial/

What to do with this

  1. Open the tutorial.
  2. Open GeometryHelpers.java.
  3. Open GeometryHelpersTest1.java. Review the test structure. Run the test.
  4. Open GeometryHelpersTest2.java.
  5. Compare the first test in GeometryHelpersTest1.java with the first test in GeometryHelpersTest2.java. See how even the smallest pieces of domain area knowledge are important?
  6. Think about what else you could test. I'm sure there is something I missed!
  7. Apply the best practices in your own project.
  8. Like the tutorial? Share, like, subscribe, say thanks. I'll be happy to know it!

How to run tests

I run this with Intellij IDEA and Java 1.8+.

  1. Download the source code.
  2. Open the folder with the code in Intellij IDEA.
  3. Open the file GeometryHelpersTest1.java. You'll see green "Run test" buttons next to line numbers. Press the one next to class GeometryHelpersTest1 and watch the whole test suite execute.

About

No description, website, or topics provided.

Resources

Releases

No releases published

Packages

No packages published

Languages