29
John Lockhart, WebTest Limited STANZ Wellington August 2010 Practical demonstration of FitNesse, FitLibrary and FitLibraryWeb

John Lockhart, WebTest Limited STANZ Wellington August 2010 Practical demonstration of FitNesse, FitLibrary and FitLibraryWeb

Embed Size (px)

Citation preview

Page 1: John Lockhart, WebTest Limited STANZ Wellington August 2010 Practical demonstration of FitNesse, FitLibrary and FitLibraryWeb

John Lockhart, WebTest LimitedSTANZ Wellington August 2010

Practical demonstration of FitNesse, FitLibrary and

FitLibraryWeb

Page 2: John Lockhart, WebTest Limited STANZ Wellington August 2010 Practical demonstration of FitNesse, FitLibrary and FitLibraryWeb

➲Enough of FitNesse, FitLibrary and FitLibraryWeb to enable you to use it on real projects.➲The demo is itself created as an "excecutable specification" in Fitnesse, to demonstrate the use of automated tests as documentation.➲This slide format means links and tests will not work. I suggest you follow the steps to install and run this talk locally.

Overview

Page 3: John Lockhart, WebTest Limited STANZ Wellington August 2010 Practical demonstration of FitNesse, FitLibrary and FitLibraryWeb

➲1. Background and intro including how to install and run the suite and its objectives.➲2. Building of a suite of tests specifying FitLibrary using FitLibraryWeb. This approach has the advantage of not requiring internet connectivity or anything except the tools themselves to be installed to run the demo.➲3. Questions/Discussion?

Format

Page 4: John Lockhart, WebTest Limited STANZ Wellington August 2010 Practical demonstration of FitNesse, FitLibrary and FitLibraryWeb

➲'Fit' was invented by Ward Cunningham in 2002➲to allow people to collaboratively express tests at a business level of abstraction➲, in the form of html tables➲and have those tests execute via specialised java classes (fixtures) which provide a mapping to the tested application.➲Ward also invented the Wiki, and + Fit = Fitnesse.➲This gave simplified table markup history subwikis/suites turning Fit from a batch style tool to a simple but effective testing framework.➲Initially these tests were basically data driven.

Background

Page 5: John Lockhart, WebTest Limited STANZ Wellington August 2010 Practical demonstration of FitNesse, FitLibrary and FitLibraryWeb

➲Rick Mugridge created FitLibrary which enhanced FitNesse in many ways e.g.:➲1. Keyword-driven testing for scenario tests

➲2. Defined actions for abstractions/macros within the wiki

➲3. Plain text format

➲FitLibraryWeb added built-in fixtures e.g. web GUI + services testing➲Rick, an Aucklander, co-wrote the first Fitnesse book with Ward. ++Good. (Gojko Adzic has also written a couple of good books – the older .Net focussed one now free).

Development up to present

Page 6: John Lockhart, WebTest Limited STANZ Wellington August 2010 Practical demonstration of FitNesse, FitLibrary and FitLibraryWeb

➲Steps (you must have java 1.6+ installed first):–1. Download zip from http://bit.ly/bbuhIf and extract–2. Double-click on run.bat file in the folder–3. Open http://localhost:8980 to see home page, which you can edit e.g. Put in links to your own suites or to pages like:–http://localhost:8980/FitLibraryWeb.SpiderFixture.SpiderTutorial

For Rick's great tutorial–http://localhost:8980/StanzDemo for this talk and demo suite.–Optionally install TortoiseSVN to give you version control then you can right click on that StanzDemo folder and choose update to get latest version.–For latest versions and instruction see link from webtest.co.nz/blog

Install and Setup

Page 7: John Lockhart, WebTest Limited STANZ Wellington August 2010 Practical demonstration of FitNesse, FitLibrary and FitLibraryWeb

The Demo Suite

Page 8: John Lockhart, WebTest Limited STANZ Wellington August 2010 Practical demonstration of FitNesse, FitLibrary and FitLibraryWeb
Page 9: John Lockhart, WebTest Limited STANZ Wellington August 2010 Practical demonstration of FitNesse, FitLibrary and FitLibraryWeb
Page 10: John Lockhart, WebTest Limited STANZ Wellington August 2010 Practical demonstration of FitNesse, FitLibrary and FitLibraryWeb
Page 11: John Lockhart, WebTest Limited STANZ Wellington August 2010 Practical demonstration of FitNesse, FitLibrary and FitLibraryWeb
Page 12: John Lockhart, WebTest Limited STANZ Wellington August 2010 Practical demonstration of FitNesse, FitLibrary and FitLibraryWeb
Page 13: John Lockhart, WebTest Limited STANZ Wellington August 2010 Practical demonstration of FitNesse, FitLibrary and FitLibraryWeb
Page 14: John Lockhart, WebTest Limited STANZ Wellington August 2010 Practical demonstration of FitNesse, FitLibrary and FitLibraryWeb
Page 15: John Lockhart, WebTest Limited STANZ Wellington August 2010 Practical demonstration of FitNesse, FitLibrary and FitLibraryWeb
Page 16: John Lockhart, WebTest Limited STANZ Wellington August 2010 Practical demonstration of FitNesse, FitLibrary and FitLibraryWeb
Page 17: John Lockhart, WebTest Limited STANZ Wellington August 2010 Practical demonstration of FitNesse, FitLibrary and FitLibraryWeb
Page 18: John Lockhart, WebTest Limited STANZ Wellington August 2010 Practical demonstration of FitNesse, FitLibrary and FitLibraryWeb

The final two defined actions

Page 19: John Lockhart, WebTest Limited STANZ Wellington August 2010 Practical demonstration of FitNesse, FitLibrary and FitLibraryWeb

Now the test in plain text form

Next page has results....

Page 20: John Lockhart, WebTest Limited STANZ Wellington August 2010 Practical demonstration of FitNesse, FitLibrary and FitLibraryWeb
Page 21: John Lockhart, WebTest Limited STANZ Wellington August 2010 Practical demonstration of FitNesse, FitLibrary and FitLibraryWeb
Page 22: John Lockhart, WebTest Limited STANZ Wellington August 2010 Practical demonstration of FitNesse, FitLibrary and FitLibraryWeb

Defined Action Format

Page 23: John Lockhart, WebTest Limited STANZ Wellington August 2010 Practical demonstration of FitNesse, FitLibrary and FitLibraryWeb
Page 24: John Lockhart, WebTest Limited STANZ Wellington August 2010 Practical demonstration of FitNesse, FitLibrary and FitLibraryWeb

The modified action and DD equiv:

Page 25: John Lockhart, WebTest Limited STANZ Wellington August 2010 Practical demonstration of FitNesse, FitLibrary and FitLibraryWeb
Page 26: John Lockhart, WebTest Limited STANZ Wellington August 2010 Practical demonstration of FitNesse, FitLibrary and FitLibraryWeb

Jmeter for Load/Perf testing

Page 27: John Lockhart, WebTest Limited STANZ Wellington August 2010 Practical demonstration of FitNesse, FitLibrary and FitLibraryWeb
Page 28: John Lockhart, WebTest Limited STANZ Wellington August 2010 Practical demonstration of FitNesse, FitLibrary and FitLibraryWeb
Page 29: John Lockhart, WebTest Limited STANZ Wellington August 2010 Practical demonstration of FitNesse, FitLibrary and FitLibraryWeb

➲Combine with a continuous build tool such as Hudson or Cruise Control so can run unattended or automatically and in parallel➲Which provide scheduling, automated running for new versions, and better management of test result history,➲And a version control systems such as Subversion or Git (though FitNesse also has its own)➲To provide a pretty complete testing solution.➲See Rick’s tutorial for tools that are useful with SpiderFixture

Recommendation