Continuous Documentation with UI-Tests Scenarioo Continuous Documentation with UI-Tests Rolf Bruderer, Adrian Herzog 27. October 2015
Rolf Bruderer Lead Software Architect Zühlke Engineering AG @bruderol rolf.bruderer@zuehlke.com Adrian Herzog Senior Software Engineer Zühlke Engineering AG @adi_herzog adrian.herzog@zuehlke.com Scenarioo Continuous Documentation with UI-Tests Rolf Bruderer, Adrian Herzog 27. October 2015
Some Famous Words Working Software over comprehensive Documentation Documentation is in the Code Code is the Documentation Tests are Documentation Scenarioo Continuous Documentation with UI-Tests Rolf Bruderer, Adrian Herzog 27. October 2015
Our Vision or Dream Software systems that document themselves Scenarioo Continuous Documentation with UI-Tests Rolf Bruderer, Adrian Herzog 27. October 2015
The Problem How does this application work? What functionalities does it support? How does a current usage scenario look? Scenarioo Continuous Documentation with UI-Tests Rolf Bruderer, Adrian Herzog 27. October 2015
One Application A lot of Questions How does this Use Case work? How does a typical Scenario through this Use Case look like? What Steps are there? Could you please send me some current Screenshots of? How do I have to interact to provoke a special scenario? What other variants of this page do exist? Which backends/ webservicesare called for this step? Did you change this since the last release? Scenarioo Continuous Documentation with UI-Tests Rolf Bruderer, Adrian Herzog 27. October 2015
The Idea: Generate it from UI Tests UI Tests (System-Tests) Documentation of Test Scenarios Automated / Continuous Scenarioo Continuous Documentation with UI-Tests Rolf Bruderer, Adrian Herzog 27. October 2015
Everybody can browse it Viewer Web Application Guidebook for your application Jump step by step through the user scenarios Accessible and understandable for everybody Scenarioo Continuous Documentation with UI-Tests Rolf Bruderer, Adrian Herzog 27. October 2015
Time for a Demo see also http://demo.scenarioo.org/ Scenarioo Continuous Documentation with UI-Tests Rolf Bruderer, Adrian Herzog 27. October 2015
Effective Collaboration with all Stakeholders Fach-Experten/ Business Requirement Engineers / Architects Common basis for collaboration Developers Support-& Application-Management Testers UI Designer Scenarioo Continuous Documentation with UI-Tests Rolf Bruderer, Adrian Herzog 27. October 2015
Image from http://www.bettycrocker.com Scenarioo Continuous Documentation with UI-Tests Rolf Bruderer, Adrian Herzog Kuchen by Florian Besser
Scenarioo Architecture Overview CI Build-System (e.g. Jenkins, Team-City, ) Application Tests App-specific Test Infrastructure Scenarioo Writer Library (Java / C# / JS / ) Scenarioo Viewer Web Application Testing Framework (JUnit, NUnit, Jasmine, ) UI Test Toolkit (e.g. Selenium, SWT-Bot, ) Scenarioo Documentation Data Application under Development Scenarioo Continuous Documentation with UI-Tests Rolf Bruderer, Adrian Herzog 27. October 2015
Scenarioo Documentation Format Branch * Build Arbitrary Application/Domainspecific information can be stored as objects in the documentation Details * Use Case can be browsed and searched in the viewer * Scenario Label * Step * 0..1 Page Screenshot Scenarioo Continuous Documentation with UI-Tests Rolf Bruderer, Adrian Herzog 27. October 2015
Scenarioo Continuous Documentation with UI-Tests Rolf Bruderer, Adrian Herzog 27. October 2015
ScenarioDocuWriter(1/3) How to create it ScenarioDocuWriter writer = new ScenarioDocuWriter( Folder where we put all our Scenarioo documentation "path/to/documentation/folder", "develop", "build_2015-10-22_17:30" Branch that we document ); Build that we document Scenarioo Continuous Documentation with UI-Tests Rolf Bruderer, Adrian Herzog 27. October 2015
ScenarioDocuWriter(2/3) How to use it writer.savebranchdescription(branch) writer.savebuilddescription(build) writer.saveusecase(usecase) writer.savescenario(usecasename,scenario) writer.savescreenshotaspng(usecasename, scenarioname, stepindex, screenshot) writer.savestep(usecasename, scenarioname, step) 1x Once for each use case Once for each scenario Once per step Scenarioo Continuous Documentation with UI-Tests Rolf Bruderer, Adrian Herzog 27. October 2015
ScenarioDocuWriter(3/3) How to flush it writer.flush(); Writing is done asynchronous Scenarioo Continuous Documentation with UI-Tests Rolf Bruderer, Adrian Herzog 27. October 2015
Code Demo Full Pizza Shop Example Code available here: https://github.com/scenarioo/pizza-delivery Scenarioo Continuous Documentation with UI-Tests Rolf Bruderer, Adrian Herzog 27. October 2015
Scenarioo Writer Usage Overview Branch * Build @ClassRulefor intercepting Test Class to document a Use Case Details * Use Case @Rule for intercepting Test Method to document a Scenario * Scenario Label Step * * 0..1 Page Screenshot EventFiringWebdriverfor storing Steps Scenarioo Continuous Documentation with UI-Tests Rolf Bruderer, Adrian Herzog 27. October 2015
Scenarioo Continuous Documentation Scenarioo Continuous Documentation with UI-Tests Rolf Bruderer, Adrian Herzog 27. October 2015
Scenarioo Continuous Documentation with UI-Tests Rolf Bruderer, Adrian Herzog 27. October 2015
Download & Use it http://www.scenarioo.org Follow & Contact us on Twitter #scenarioo @bruderol @adi_herzog Collaborate & Contribute https://github.com/scenarioo Scenarioo Continuous Documentation with UI-Tests Rolf Bruderer, Adrian Herzog 27. October 2015