My own preferred testing
techniques
Paris Java User Group
www.parisjug.org
Copyright(c) 2010 Paris JUG, Licence CC-Creatives Commons 2.0 France - Paternité - Pas d’utilisation comm...
Frameworks
My own preferred testing techniques
JUnit 4+
More expressive tests
More robust
Faster
Plugins
Personal taste only
Plugins
MoreUnit, a unit test friendly Eclipse
http://moreunit.sourceforge.net/
See what’s tested
MoreUnit
http://moreunit.sourceforge.net/
Jump to Test
MoreUnit
http://moreunit.sourceforge.net/
Run current test
Refactoring friendly
(move, rename, delete)
http://moreunit.sou...
Continuous testing
Runs all impacted tests after each code change
Eclipse and Intellij
OpenSource, Free
http://infinitest.o...
Demo
Continuous testing
JUnit Max
Runs all impacted tests after each code change
Try to run tests failing most often, first
Ecli...
Frameworks
Hamcrest
More readable assertions
Hamcrest
More samples
+ easy to write custom matchers
So
FEST-Assert
More readable assertions
Demo
FEST-Assert
More readable assertions
OpenSource
http://fest.easytesting.org/
JUnit 4.8.2
Worst logo
ever!
Do you known/use all the features?
@Test
@Before, @After, @BeforeClass, @AfterClass
@RunWith
@Theory, @DataPoint(s)
@Rule
...
@Categories and @SuiteClasses
JUnit 4.8.2
@Categories and @SuiteClasses
JUnit 4.8.2
@Categories and @SuiteClasses
JUnit 4.8.2
Cumbersome
Need not forget to add each
test manually in all suites
Who doesn’t r...
@Rule
Take a look at the code of MethodRule,
ExternalResource, TestWatchman, Verifier...
Write your own rules if they make ...
Thank you
Q/A
www.parisjug.org
Copyright(c) 2010 Paris JUG, Licence CC-Creatives Commons 2.0 France - Paternité - Pas d’utilisation comm...
Upcoming SlideShare
Loading in...5
×

My own preferred testing tools - Paris JUG 2011

1,039

Published on

Published in: Technology
0 Comments
0 Likes
Statistics
Notes
  • Be the first to comment

  • Be the first to like this

No Downloads
Views
Total Views
1,039
On Slideshare
0
From Embeds
0
Number of Embeds
1
Actions
Shares
0
Downloads
6
Comments
0
Likes
0
Embeds 0
No embeds

No notes for slide

My own preferred testing tools - Paris JUG 2011

  1. 1. My own preferred testing techniques Paris Java User Group
  2. 2. www.parisjug.org Copyright(c) 2010 Paris JUG, Licence CC-Creatives Commons 2.0 France - Paternité - Pas d’utilisation commerciale - Partage des Conditions à l’identique
  3. 3. Frameworks My own preferred testing techniques JUnit 4+ More expressive tests More robust Faster Plugins
  4. 4. Personal taste only
  5. 5. Plugins
  6. 6. MoreUnit, a unit test friendly Eclipse http://moreunit.sourceforge.net/ See what’s tested
  7. 7. MoreUnit http://moreunit.sourceforge.net/ Jump to Test
  8. 8. MoreUnit http://moreunit.sourceforge.net/ Run current test Refactoring friendly (move, rename, delete) http://moreunit.sourceforge.net/ Demo
  9. 9. Continuous testing Runs all impacted tests after each code change Eclipse and Intellij OpenSource, Free http://infinitest.org
  10. 10. Demo
  11. 11. Continuous testing JUnit Max Runs all impacted tests after each code change Try to run tests failing most often, first Eclipse and Intellij OpenSource, Free Developed by Kent Beck http://www.junitmax.com/
  12. 12. Frameworks
  13. 13. Hamcrest More readable assertions
  14. 14. Hamcrest More samples + easy to write custom matchers
  15. 15. So
  16. 16. FEST-Assert More readable assertions Demo
  17. 17. FEST-Assert More readable assertions OpenSource http://fest.easytesting.org/
  18. 18. JUnit 4.8.2 Worst logo ever!
  19. 19. Do you known/use all the features? @Test @Before, @After, @BeforeClass, @AfterClass @RunWith @Theory, @DataPoint(s) @Rule @SuiteClasses @Category (beta) JUnit 4.8.2 Demo
  20. 20. @Categories and @SuiteClasses JUnit 4.8.2
  21. 21. @Categories and @SuiteClasses JUnit 4.8.2
  22. 22. @Categories and @SuiteClasses JUnit 4.8.2 Cumbersome Need not forget to add each test manually in all suites Who doesn’t run all the tests every build? :-)
  23. 23. @Rule Take a look at the code of MethodRule, ExternalResource, TestWatchman, Verifier... Write your own rules if they make the tests easier to read. JUnit 4.8.2
  24. 24. Thank you Q/A
  25. 25. www.parisjug.org Copyright(c) 2010 Paris JUG, Licence CC-Creatives Commons 2.0 France - Paternité - Pas d’utilisation commerciale - Partage des Conditions à l’identique
  1. A particular slide catching your eye?

    Clipping is a handy way to collect important slides you want to go back to later.

×