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.
1. 1/23/2013
Star Canada
April 2013, Toronto
Janet Gregory, DragonFire Inc.
Copyright 2013
Copyright 2013
DragonFire Inc.
First agile team – 2000
Currently – coaching, testing
Book – Agile Testing; January 2009
Writing Book 2 - 2013
2
1
2. 1/23/2013
3
1.
2.
3.
4.
5.
mixed messages by thought leaders
new technologies
distributed teams
organization culture
tester role / testing activities / automation
Are there others you can think of ???
Copyright 2013
DragonFire Inc.
4
2
5. 1/23/2013
test /
examples
TestLogIn
User Name
Password Expected result
JanetGregory Password Access system as JanetGregory
Janet Gregory Password Error
comments
Valid combo saved
Space in user name
boolean TestLogIn (userName, password, expected result)
call LogIn (userName, password)
compare (actual result, expected result)
if true, return pass
else
return fail
test method
/ fixture
end
Developer
code
Copyright 2013
DragonFire Inc.
boolean LogIn (name,pwd)
code stuff ………..
if logged in, return true
else
return false
end
• 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
Copyright 2013
DragonFire Inc.
10
5
7. 1/23/2013
• 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
Copyright 2013
DragonFire Inc.
14
7
8. 1/23/2013
• 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
Copyright 2013
DragonFire Inc.
15
So, if we can’t test all (most) functionality at
the API layer ...
Any stories to share?
Copyright 2013
DragonFire Inc.
16
8
10. 1/23/2013
• system architecture
◦ high level (context)
◦ component level
Thx to Lynn McKee for the term technical awareness
19
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?
Copyright 2013
DragonFire Inc.
20
10