Software Engineering I cs361 Test Driven Development What is Test - - PowerPoint PPT Presentation

software engineering i cs361 test driven development
SMART_READER_LITE
LIVE PREVIEW

Software Engineering I cs361 Test Driven Development What is Test - - PowerPoint PPT Presentation

Software Engineering I cs361 Test Driven Development What is Test Driven Development (TDD) Test-driven development ( TDD ) is a software development process based on three simple rules TDD Rules (From Uncle Bob Martin) 1. You are not allowed


slide-1
SLIDE 1

Software Engineering I cs361

slide-2
SLIDE 2

Test Driven Development

slide-3
SLIDE 3

What is Test Driven Development (TDD)

Test-driven development (TDD) is a software development process based on three simple rules

slide-4
SLIDE 4

TDD Rules (From Uncle Bob Martin)

  • 1. You are not allowed to write

any production code unless it is to make a failing unit test pass

slide-5
SLIDE 5

TDD Rules (From Uncle Bob Martin)

  • 1. You are not allowed to write

any production code unless it is to make a failing unit test pass 2.You are not allowed to write any more of a unit test then is sufficient to fail; and any compilation failures are failures

slide-6
SLIDE 6

TDD Rules (From Uncle Bob Martin)

  • 1. You are not allowed to write any

production code unless it is to make a failing unit test pass 2.You are not allowed to write any more

  • f a unit test then is sufficient to fail;

and any compilation failures are failures

  • 3. You are not allowed to write any more

production code than is sufficient to pass the one failing unit test

slide-7
SLIDE 7

TDD Cycle

Write a test that fails Refactor (as needed) Write code to pass test

slide-8
SLIDE 8

Class Exercise

slide-9
SLIDE 9

FizzBuzz

✖ If number is divisible by 3, print Fizz ✖ If number is divisible by 5 print Buzz ✖ if number is neither, print number

slide-10
SLIDE 10

Assignments

slide-11
SLIDE 11

Writing Assignment 1

✖ http:// web.engr.oregonstate.edu/ ~hiltonm/classes/cs361/ assignment0.html

slide-12
SLIDE 12

Team Project Assignment 1

✖ http:// web.engr.oregonstate.edu/ ~hiltonm/classes/cs361/ assignment1.html

slide-13
SLIDE 13

User Stories

slide-14
SLIDE 14

User Stories

✖ The Card ✖ The Conversation ✖ The Confirmation

slide-15
SLIDE 15

Src: https://www.flickr.com/photos/jakuza/2728096478

slide-16
SLIDE 16

The Card

“As a [role], I want [function], so that [value]” Often written on 3x5 card Examples:

slide-17
SLIDE 17

The Conversation

An open dialog between everyone working on the project and the client Split up Epic Stories if Needed

slide-18
SLIDE 18

The Confirmation

A test that will show when task is completed Could be automated, or a script

slide-19
SLIDE 19

Credits

Special thanks to all the people who made and released these awesome resources for free: ✖ Presentation template by SlidesCarnival ✖ Photographs by Unsplash