Excel TDD - PowerPoint PPT Presentation

1 / 31
About This Presentation
Title:

Excel TDD

Description:

A regression test suite naturally evolved with the system. The system was really easy to change ... is fun and addictive. Next steps ... – PowerPoint PPT presentation

Number of Views:58
Avg rating:3.0/5.0
Slides: 32
Provided by: clarke2
Category:
Tags: tdd | addictive | excel

less

Transcript and Presenter's Notes

Title: Excel TDD


1
Excel _at_ TDD
  • An introduction to how to keep software soft
  • Karl Scotland

2
What if
  • Everything worked one minute ago
  • A regression test suite naturally evolved with
    the system
  • The system was really easy to change
  • Developers had examples to help understand code
  • The system design was easy to test
  • Developers were addicted to having a working
    system

3
An example using Excel and VBA
  • Convert integers to Roman numerals
  • Assume ROMAN() does not exist
  • Imagine Im actually in Excel

4
i2r(A2)
5
i2r
6
(No Transcript)
7
Shift-F9 runs the tests
8
(No Transcript)
9
(No Transcript)
10
IF(B2C2, Pass, Fail)
11
(No Transcript)
12
(No Transcript)
13
(No Transcript)
14
(No Transcript)
15
(No Transcript)
16
(No Transcript)
17
(No Transcript)
18
(No Transcript)
19
(No Transcript)
20
i, ii, iii pattern
Repeated here
21
(No Transcript)
22
(No Transcript)
23
(No Transcript)
24
(No Transcript)
25
What Just Happened
  • Took baby steps
  • Red ? Green ? Refactor
  • Hard coded values (Fake it till you Make it)
  • Evolved the design
  • Expected failures
  • Found typo almost immediately
  • Used Excel and VBA

26
What if
  • Everything worked one minute ago
  • A regression test suite naturally evolved with
    the system
  • The system was really easy to change
  • Developers had examples to help understand code
  • The systems design was easy to test
  • Developers were addicted to having a working
    system

27
Objections
  • What would make TDD difficult?

28
Objections
  • We dont have time
  • We have legacy code
  • We have GUIs
  • We have Databases
  • TDD wont find bugs
  • What about QA?
  • We wont do it

29
My Experience
  • TDD
  • does not add time
  • saves time
  • produces high quality design and code
  • supports iterative, incremental development
  • is fun and addictive

30
Next steps
  • Test-Driven Development by Example Kent Beck
    (Addison Wesley 2002)
  • JUnit, phpUnit etc.
  • http//www.testdriven.com
  • Ping me (kjscotland)
  • Try it!

31
Questions?
Write a Comment
User Comments (0)
About PowerShow.com