Skip to content

Wakaleo Consulting

  Home

items tagged with Unit Testing

Test-Driven Development and Software Quality
Written By: Administrator
Section: Articles and Resources

Category: Blog

2008-05-26 00:00:00

Any Test-Driven Development practitioner will tell you, Test-Driven Development is a design strategy, not a unit-testing technique. Writing unit tests are a means, not an end. The goal is to write better quality, more reliable, and more accurate code.


Read More About Test-Driven Development And Software Quality...


Testing Exceptions in JUnit 4.7
Written By: Administrator
Section: Articles and Resources

Category: Blog

2009-09-27 20:48:38

JUnit 4.7 introduced a few features that make it a little easier to work with exceptions. JUnit 4 introduced the expected parameter, which makes a test succeed if and only if a certain exception is thrown. For example, in the following code sample, we are testing a UserManager class. When the login() function is called, it should throw an UnknownUserException when no user is found.


Read More About Testing Exceptions In JUnit 4.7...


Tests first or tests last - come on, who cares?
Written By: Administrator
Section: Articles and Resources

Category: Blog

2008-06-02 00:00:00

Let's not be pedantic. Write unit tests before you code a method, or after it - in my experience, it matters little, as long as you think about and write the tests at roughly the same time as you write the code. It's coming back to do the tests later (or not coming back at all) which causes problems. Personally, I like to write unit tests just before or immediately after writing small chunks of code - it doesn't break the flow, because it is part of the flow.


Read More About Tests First Or Tests Last - Come On, Who Cares?...


Working with temporary files in JUnit 4.7
Written By: Administrator
Section: Articles and Resources

Category: Blog

2009-09-29 12:00:00

Another handy feature in JUnit 4.7 is the TemporaryFolder @Rule. Using this rule, JUnit will create a temporary folder before your test, and delete it afterwards, whether the test passes or fails. This comes in very handy for tests involving file manipulation of any sort.


Read More About Working With Temporary Files In JUnit 4.7...





There are 4 items tagged with Unit Testing. You can view all our tags in the Tag Cloud

<< Start < Previous 1 Next > End >>
Page 1 Of 1