testing challenges within agile teams
DESCRIPTION
In her book Agile Testing: A Practical Guide for Testers and Agile Teams, Janet Gregory recommends using the automation pyramid as a model for test coverage. In the pyramid model, most automated tests are unit tests written and maintained by the programmers,and tests that execute below the user interface—API-level tests that can be developed and maintained collaboratively by programmers and testers. However, as agile becomes mainstream, some circumstances may challenge this model. Many applications are transferring logic back to the client side by using programming languages such as JavaScript. Legacy systems, using languages such as COBOL, don’t have access to unit testing frameworks. Janet shows how to adapt the model to your needs and addresses some of these automation issues. During the session, delegates are encouraged to share their challenges and success stories.TRANSCRIPT
1/23/2013
1
Janet Gregory, DragonFire Inc.Copyright 2013
Star Canada April 2013, Toronto
Copyright 2013 DragonFire Inc.
First agile team – 2000Currently – coaching, testingBook – Agile Testing; January 2009Writing Book 2 - 2013
2
1/23/2013
2
3
Copyright 2013 DragonFire Inc.
1. mixed messages by thought leaders 2. new technologies3. distributed teams4. organization culture 5. tester role / testing activities / automation
Are there others you can think of ???
4
1/23/2013
3
Testing activitiesTesting activities
Common automation modelCommon automation model
Automation through the
GUI
Unit Tests
1/23/2013
4
push the tests lower
Automate at the feature
level
Automate at the story
level
Automate at the task
level
Copyright 2013 DragonFire Inc.
Tests / Examples
Test Method / Fixture
Developer Code
passes to
calls
API test structure Test
Framework
1/23/2013
5
Copyright 2013 DragonFire Inc.
boolean TestLogIn (userName, password, expected result)call LogIn (userName, password)compare (actual result, expected result)if true, return passelse return fail
end
User Name Password Expected result commentsJanetGregory Password Access system as JanetGregory Valid combo savedJanet Gregory Password Error Space in user name
TestLogIn
boolean LogIn (name,pwd)code stuff ……….. if logged in, return true
elsereturn false
end
test / examples
test method / fixture
Developer code
Copyright 2013 DragonFire Inc.
• different model for your application• old technologies (ex. Cobol)• less abstraction between layers◦ presentation vs. business layer
• new technologies◦ more logic in the GUI layer
10
1/23/2013
6
• JavaScript• Flash• Flex• Ajax• Cross-browser
compatibility• Mobile (type,
carrier, networks)
12
1/23/2013
7
Copyright 2013 DragonFire Inc.
• ATDD (acceptance test driven dev) through the GUI◦ Jasmine: BDD framework to test JavaScript◦ Sebium: Fit and Selenium combined (Cirilo Wortel)◦ Selenium: possible, but harder◦ Ruby / Watir: possible, but harder
• Unit tests◦ jQuery
14
1/23/2013
8
Copyright 2013 DragonFire Inc.
• enables testers / business to define tests
• test code can be in programming language
• programmers can run tests as they code
• testers can ask programmers for help
• takes time from ‘coding’ production code
• tests are usually through the UI
• programmers aren’t usually willing to help
• tests are implemented after the code is written
• testers create and implement all tests
15
Copyright 2013 DragonFire Inc.
So, if we can’t test all (most) functionality at the API layer ...
Any stories to share?
16
1/23/2013
9
17
two big questions ....two big questions ....
Do testers need to know how to code?
18
Can programmers
do all the testing?
1/23/2013
10
• system architecture◦ high level (context)◦ component level
19Thx to Lynn McKee for the term technical awareness
Copyright 2013 DragonFire Inc.
for example, • in JavaScript, there is a small, but important
issue with the parseInt function, used to transform strings to integers. • the issue arises when we create a Date object
from a 'yyyy-mm-dd' string.
Could your testers and programmers have a conversation about this?
20
1/23/2013
11
Copyright 2013 DragonFire Inc. 21
Brian Marick
1/23/2013
12
23
Copyright 2013 DragonFire Inc.
• slicing stories• ATDD (acceptance test driven development)• sharing technical details• teaching testing skills• learning test patterns• learning / teaching design techniques• creating test harnesses, mocks, stubs
24
1/23/2013
13
Copyright 2013 DragonFire Inc. 25
Copyright 2013 DragonFire Inc.
Instead of saying NO, or being the gatekeeper
Be the information provider so business can make the decisions
Questions?
26
1/23/2013
14
Copyright 2013 DragonFire Inc.
• [email protected]• www.lisacrispin.com• http://gojko.net/2010/10/05/rethinking-user-interface-test-
automation/• http://net.tutsplus.com/tutorials/javascript-ajax/testing-your-
javascript-with-jasmine• http://www.software-testing.com.au/blog/2011/01/25/test-
automation-styles-and-alternatives-to-the-page-object-pattern/
• www.qualityperspectives.ca
27
Copyright 2013 DragonFire Inc.
Contact Information
twitter: @janetgregoryca
[email protected]: @lisacrispin
www.agiletester.ca