+ All Categories
Home > Technology > BDD with F# at DDDScot

BDD with F# at DDDScot

Date post: 06-May-2015
Category:
Upload: phillip-trelford
View: 1,811 times
Download: 4 times
Share this document with a friend
Description:
Talk presented in Glasgow at DDD Scotalnd in May 2011. Abstract: http://developerdeveloperdeveloper.com/scotland2011/ViewSession.aspx?SessionID=724
26
BDD with F# Phillip Trelford @ptrelford http://trelford.com/blog
Transcript
Page 1: BDD with F# at DDDScot

BDD with F#Phillip Trelford

@ptrelfordhttp://trelford.com/blog

Page 2: BDD with F# at DDDScot

Jargon Buster

0FP = Functional Programming0 Immutable = Doesn’t change0 Idempotent = Free from side effects0DSL = Domain Specific Language 0BDD = Behaviour Driven Development

0Agile Acceptance Testing0Acceptance-Test Driven Development 0Story-Testing0Specification by Example

Page 3: BDD with F# at DDDScot

Fun and Profit

0 Introduction0Fun with F#

0 Intro -> Code -> What next0Profit with BDD

0 Intro -> Code -> What next0Q & A

Page 4: BDD with F# at DDDScot

Functional

Page 5: BDD with F# at DDDScot

Myth 1

“F# is a purely functional

programming language”

Page 6: BDD with F# at DDDScot

F# is more a mix of

F#

C#

OCamlPython

Page 7: BDD with F# at DDDScot

Code Samples

1: // Declare a local value (inferred type is string)2: let world = "world"3: 4: // Using '%s' format specifier to include string parameter

5: printfn "Hello %s!" world

 

Page 8: BDD with F# at DDDScot

Myth 2

“FP is slow”

Page 9: BDD with F# at DDDScot

Performance

Page 10: BDD with F# at DDDScot

Myth 3

“F# is Academic”

Page 11: BDD with F# at DDDScot

Commercial Users

We could not have developed 200 models in two years without F# and Visual Studio. It would have taken us at least twice as long with our previous tools.

Directorlarge European financial services firm

Page 12: BDD with F# at DDDScot

F# Books

Page 13: BDD with F# at DDDScot

Meet the F#ers

@rickasaurus

@tomaspetricek

@dmohl

Page 14: BDD with F# at DDDScot

Agile Manifesto

0 Individuals and interactions over processes and tools

0 Working software over comprehensive documentation

0 Customer collaboration over contract negotiation

0 Responding to change over following a plan

Page 15: BDD with F# at DDDScot

User Stories

Page 16: BDD with F# at DDDScot

Acceptance Test Scenario

Refunded items should be returned to stock0Given a customer buys a black jumper0And I have 3 black jumpers left in stock0When he returns the black jumper for a refund0Then I should have 4 black jumpers in stock

Page 17: BDD with F# at DDDScot

Behaviour Driven Development

“Acceptance criteria should be executable”- Dan North in Introducing BDD Article

Page 18: BDD with F# at DDDScot

First Steps in BDD on .Net

•Shell•C# &

F#

StorEvil•Visu

al Studio

•C#SpecFlow

•F# & C#

•VS & Shell

?

?

Visual Studio

NUnitGherkin

Page 19: BDD with F# at DDDScot

Look no hands

Page 20: BDD with F# at DDDScot

Look no hands

Page 21: BDD with F# at DDDScot

TickSpec

Page 22: BDD with F# at DDDScot

Demo

Page 23: BDD with F# at DDDScot

BDD Books

Page 24: BDD with F# at DDDScot

Lifetime BDD Awards

@tastapod

@lunivore

@gojkoadzic

Page 25: BDD with F# at DDDScot

@jbandi

#chtd Quote from "future of .net " Have a look at F# for two days and you will find yourself two years ahead of your peer .net devs. #fsharp

Page 26: BDD with F# at DDDScot

Q & A

Or contact me in confidence:0Twitter: @ptrelford0E-mail: phil(at)trelford.com0 In-person: http://meetup.com/FSharpLondon


Recommended