tdd your jquery plugins

Post on 06-May-2015

2.260 Views

Category:

Technology

0 Downloads

Preview:

Click to see full reader

TRANSCRIPT

TDD YOURJQUERYPLUGINSPRESENTED BY

PAUL ELLIOTT@p_elliott

HASHROCKETEXPERTLY CRAFTED WEB

Monday, October 18, 2010

PAUL ELLIOTTTDD YOUR JQUERY PLUGINS

test all the time

Monday, October 18, 2010

PAUL ELLIOTTTDD YOUR JQUERY PLUGINS

testing frameworks

Monday, October 18, 2010

PAUL ELLIOTTTDD YOUR JQUERY PLUGINS

it’s not about bugs

Monday, October 18, 2010

PAUL ELLIOTTTDD YOUR JQUERY PLUGINS

what is TDD?

Monday, October 18, 2010

PAUL ELLIOTTTDD YOUR JQUERY PLUGINS

QUnit

Monday, October 18, 2010

PAUL ELLIOTTTDD YOUR JQUERY PLUGINS

outside in

Monday, October 18, 2010

PAUL ELLIOTTTDD YOUR JQUERY PLUGINS

let’s build a plugin!

Monday, October 18, 2010

PAUL ELLIOTTTDD YOUR JQUERY PLUGINS

“default value” for form fields

Monday, October 18, 2010

PAUL ELLIOTTTDD YOUR JQUERY PLUGINS

only for text inputs

Monday, October 18, 2010

PAUL ELLIOTTTDD YOUR JQUERY PLUGINS

sets default if no value presentinitially and on blur

Monday, October 18, 2010

PAUL ELLIOTTTDD YOUR JQUERY PLUGINS

clears defaulton focus and form submission

Monday, October 18, 2010

PAUL ELLIOTTTDD YOUR JQUERY PLUGINS

step 1: set up your test suite

Monday, October 18, 2010

PAUL ELLIOTTTDD YOUR JQUERY PLUGINS

Monday, October 18, 2010

PAUL ELLIOTTTDD YOUR JQUERY PLUGINS

Monday, October 18, 2010

PAUL ELLIOTTTDD YOUR JQUERY PLUGINS

step 2: make your first failure

Monday, October 18, 2010

TDD YOUR JQUERY PLUGINS PAUL ELLIOTT

integration

Monday, October 18, 2010

TDD YOUR JQUERY PLUGINS PAUL ELLIOTT

integration

Monday, October 18, 2010

PAUL ELLIOTTTDD YOUR JQUERY PLUGINS

step 3: write your first test

Monday, October 18, 2010

PAUL ELLIOTTTDD YOUR JQUERY PLUGINS

Monday, October 18, 2010

PAUL ELLIOTTTDD YOUR JQUERY PLUGINS

Monday, October 18, 2010

PAUL ELLIOTTTDD YOUR JQUERY PLUGINS

one feature at a time

Monday, October 18, 2010

TDD YOUR JQUERY PLUGINS PAUL ELLIOTT

integration

Monday, October 18, 2010

TDD YOUR JQUERY PLUGINS PAUL ELLIOTT

integration

Monday, October 18, 2010

TDD YOUR JQUERY PLUGINS PAUL ELLIOTT

integration

Monday, October 18, 2010

TDD YOUR JQUERY PLUGINS PAUL ELLIOTT

integration

Monday, October 18, 2010

PAUL ELLIOTTTDD YOUR JQUERY PLUGINS

pay attention to patterns

Monday, October 18, 2010

TDD YOUR JQUERY PLUGINS PAUL ELLIOTT

Monday, October 18, 2010

TDD YOUR JQUERY PLUGINS PAUL ELLIOTT

Monday, October 18, 2010

PAUL ELLIOTTTDD YOUR JQUERY PLUGINS

Monday, October 18, 2010

PAUL ELLIOTTTDD YOUR JQUERY PLUGINS

Monday, October 18, 2010

PAUL ELLIOTTTDD YOUR JQUERY PLUGINS

keep on alternating

Monday, October 18, 2010

PAUL ELLIOTTTDD YOUR JQUERY PLUGINS

Monday, October 18, 2010

PAUL ELLIOTTTDD YOUR JQUERY PLUGINS

Monday, October 18, 2010

PAUL ELLIOTTTDD YOUR JQUERY PLUGINS

you are now free to refactor

Monday, October 18, 2010

PAUL ELLIOTTTDD YOUR JQUERY PLUGINS

Monday, October 18, 2010

PAUL ELLIOTTTDD YOUR JQUERY PLUGINS

Monday, October 18, 2010

PAUL ELLIOTTTDD YOUR JQUERY PLUGINS

github.com/paulelliott/jquery-tdd-example

Monday, October 18, 2010

PAUL ELLIOTTTDD YOUR JQUERY PLUGINS

Got Questions?I want to hear from you!

Monday, October 18, 2010

HASHROCKETEXPERTLY CRAFTED WEB

Thank you

paul@hashrocket.com@p_elliott

Paul Elliott

http://docs.jquery.com/Qunithttp://github.com/paulelliott/jquery-tdd-example

Monday, October 18, 2010

top related