1 / 14

Test Driving Your S-Wing

Test Driving Your S-Wing. By Patrick Kua emailpat <at> thekua.com || pkua <at> thoughtworks.com. The Agenda. Unit Integration Tests x 10. Unit Tests x 100s. 0010110101010110 1010001011010101 1010100010110101 0101101010001012 1010101011010100 1011010101011100 1010001011000010. Code.

rose-hudson
Download Presentation

Test Driving Your S-Wing

An Image/Link below is provided (as is) to download presentation Download Policy: Content on the Website is provided to you AS IS for your information and personal use and may not be sold / licensed / shared on other websites without getting consent from its author. Content is provided to you AS IS for your information and personal use only. Download presentation by click this link. While downloading, if for some reason you are not able to download a presentation, the publisher may have deleted the file from their server. During download, if you can't get a presentation, the file might be deleted by the publisher.

E N D

Presentation Transcript


  1. Test Driving Your S-Wing By Patrick Kua emailpat <at> thekua.com || pkua <at> thoughtworks.com

  2. The Agenda

  3. Unit Integration Tests x 10 Unit Tests x 100s 0010110101010110101000101101010110101000101101010101101010001012101010101101010010110101010111001010001011000010 Code Developer Loop Acceptance Tests x1

  4. Writing Acceptance Tests

  5. Confirm Exit As an author I would like to be prompted for confirmation on exit so that I do not lose any unsaved changes

  6. VS Source Test

  7. public void testOnExitIAmAskedForConfirmation() { MainApplication application = TestHelper.getMainApplication(); ConfirmationDialog dialog = application.clickExit(); assertNotNull(dialog); assertEquals(“Are you sure you want to Exit?”, dialog.getMessage()); dialog.clickCancel(); assertTrue(application.isShowing()); }

  8. How To Implement • No Frameworks (yay!) • Model View Presenter • Test Things Only Worth Testing • Unit Test as Much as Possible • Code Changes Based on Tests • Demonstration…

  9. Glue Layout Managers Presenters Views Repository How it all works (Yawn… I mean Architecture)

  10. Implementing Confirmation of Exit Actually Exit

  11. Abbot & Costello Alternatives include: • Marathon Man • http://marathonman.sourceforge.net • Jemmy (Netbeans) • http://jacareto.sourceforge.net • Jacreto • http://jacareto.sourceforge.net • JFC Unit • http://jfcunit.sourceforge.net • Pounder • http://pounder.sourceforge.net http://abbot.sourceforge.net/

  12. Robust Acceptance Tests

  13. Top Tips

  14. The resources for this presentation can be found at: http://www.thekua.com/conferences/xp2006 Questions?

More Related