Slide 1

Slide 1 text

Embracing Python for Software Testing - BDD Style PyCon Ireland 2012 Jakub Jarosz http://testing.gobanana.co.uk/?p=743

Slide 2

Slide 2 text

test & deployment automation

Slide 3

Slide 3 text

softtest ireland softtest.ie #SoftTestIreland

Slide 4

Slide 4 text

today's menu: test evolution challenges communication specification

Slide 5

Slide 5 text

http://advancedlifeskills.com/blog/do-you-see-blessings-in-challenges/

Slide 6

Slide 6 text

big picture... UI midlayer back end - engine reports UI

Slide 7

Slide 7 text

stack UI midlayer back end - engine reports UI C++

Slide 8

Slide 8 text

testing UI midlayer back end - engine reports UI

Slide 9

Slide 9 text

focus UI midlayer back end - engine reports UI

Slide 10

Slide 10 text

back end overview

Slide 11

Slide 11 text

rules & statistics http://mikelperez.wikispaces.com/

Slide 12

Slide 12 text

test evolution... http://www.facefinal.com/2012/09/100-reasons-why-evolution-is-so-stupid.html#.UHeYJRZ25mE

Slide 13

Slide 13 text

preconditions

Slide 14

Slide 14 text

REST - the manual way

Slide 15

Slide 15 text

manual testing... http://blog.chriss-baumann.de/2010/07/26/because-life-is-too-short-for-manual-testing

Slide 16

Slide 16 text

automating

Slide 17

Slide 17 text

pyUnit http://www.oracleunittesting.com/unit-testing/part-4-how-do-unit-tests-work/

Slide 18

Slide 18 text

use & test case DB SUT preconditions REST

Slide 19

Slide 19 text

No content

Slide 20

Slide 20 text

No content

Slide 21

Slide 21 text

Gherkin to the rescue GIVEN a registered user 'bob' WHEN a user navigates to the Sign In page AND the user signs in as 'bob' THEN the profile page for 'bob' will be displayed

Slide 22

Slide 22 text

Business readable specification http://images.businessweek.com/ss/09/06/0630_contract_workers/4.htm

Slide 23

Slide 23 text

Describe software behaviour... ... without detailing how that behaviour is implemented. http://www.uea.ac.uk/~m242/nasc/cross/cman/howbig.htm

Slide 24

Slide 24 text

BDD - testing stack PROJECT Steps Features Scenarios

Slide 25

Slide 25 text

BDD - testing stack PROJECT Steps Features Scenarios Step definitions Support code Automation library SYSTEM

Slide 26

Slide 26 text

BDD - testing stack PROJECT Steps Features Scenarios Step definitions Support code Automation library SYSTEM BUSINESS TECHNOLOGY

Slide 27

Slide 27 text

collaboration http://oecdeducationtoday.blogspot.com/2012/05/what-should-students-learn-in-21st.html

Slide 28

Slide 28 text

lettuce http://www.bigoven.com/recipes/Lettuce/title

Slide 29

Slide 29 text

project structure

Slide 30

Slide 30 text

project structure - BDD

Slide 31

Slide 31 text

project structure - libs & unittest

Slide 32

Slide 32 text

lettuce

Slide 33

Slide 33 text

lettuce steps definition

Slide 34

Slide 34 text

lettuce - Given

Slide 35

Slide 35 text

lettuce - When

Slide 36

Slide 36 text

lettuce - Then

Slide 37

Slide 37 text

lettuce run... http://thnxfrthememories.blogspot.com/2010/07/run-forrest-run.html

Slide 38

Slide 38 text

lettuce run...

Slide 39

Slide 39 text

CI server $ lettuce security_buffer.feature --with- xunit

Slide 40

Slide 40 text

http://www.zazzle.com/its_not_what_you_believe_but_how_you_behave_magnet-147580983275159945

Slide 41

Slide 41 text

Project structure

Slide 42

Slide 42 text

statistics http://mikelperez.wikispaces.com/

Slide 43

Slide 43 text

No content

Slide 44

Slide 44 text

No content

Slide 45

Slide 45 text

No content

Slide 46

Slide 46 text

Steps http://www.creativetriage.com/2010/11/02/8-steps-a-day-to-community-hospital-social-media-success/

Slide 47

Slide 47 text

No content

Slide 48

Slide 48 text

No content

Slide 49

Slide 49 text

web console http://mikelperez.wikispaces.com/

Slide 50

Slide 50 text

No content

Slide 51

Slide 51 text

Steps http://www.creativetriage.com/2010/11/02/8-steps-a-day-to-community-hospital-social-media-success/

Slide 52

Slide 52 text

No content

Slide 53

Slide 53 text

No content

Slide 54

Slide 54 text

No content

Slide 55

Slide 55 text

No content

Slide 56

Slide 56 text

No content

Slide 57

Slide 57 text

CI server $ $ behave ec_web_console_2.feature --junit

Slide 58

Slide 58 text

Jakub Jarosz @jakubjarosz http://testing.gobanana.co.uk/?p=743 Thank You ! Q & A