Upgrade to Pro
— share decks privately, control downloads, hide ads and more …
Speaker Deck
Features
Speaker Deck
PRO
Sign in
Sign up for free
Search
Search
TDD IRL
Search
delucas
September 09, 2014
Technology
1
120
TDD IRL
Charla de TDD dada en la UTN F.R. Rosario, el día 09/09/2014
delucas
September 09, 2014
Tweet
Share
More Decks by delucas
See All by delucas
TBD - Too Busy Disorder
delucas
0
530
Gamification
delucas
1
130
Pedacitos de rubí
delucas
0
78
¿Aún no usás git y GitHub?
delucas
0
51
Desarrollo de Aplicaciones Móviles - Maestría en Informática
delucas
0
140
You already git started. Now... what?
delucas
3
140
TDD IRL reloaded
delucas
0
89
Adaptación de una plataforma de e-learning a nuevos entornos
delucas
0
250
Introducción wecode.io
delucas
0
70
Other Decks in Technology
See All in Technology
株式会社ログラス - 会社説明資料【エンジニア】/ Loglass Engineer
loglass2019
4
65k
スクラムガイドに載っていないスクラムのはじめかた - チームでスクラムをはじめるときに知っておきたい勘所を集めてみました! - / How to start Scrum that is not written in the Scrum Guide 2nd
takaking22
2
210
初めてAWSを使うときのセキュリティ覚書〜初心者支部編〜
cmusudakeisuke
1
280
開発者を支える Internal Developer Portal のイマとコレカラ / To-day and To-morrow of Internal Developer Portals: Supporting Developers
aoto
PRO
1
480
RSCの時代にReactとフレームワークの境界を探る
uhyo
11
3.5k
AI時代を生き抜くエンジニアキャリアの築き方 (AI-Native 時代、エンジニアという道は 「最大の挑戦の場」となる) / Building an Engineering Career to Thrive in the Age of AI (In the AI-Native Era, the Path of Engineering Becomes the Ultimate Arena of Challenge)
jeongjaesoon
0
260
20250913_JAWS_sysad_kobe
takuyay0ne
2
250
品質視点から考える組織デザイン/Organizational Design from Quality
mii3king
0
210
Generative AI Japan 第一回生成AI実践研究会「AI駆動開発の現在地──ブレイクスルーの鍵を握るのはデータ領域」
shisyu_gaku
0
330
roppongirb_20250911
igaiga
1
250
機械学習を扱うプラットフォーム開発と運用事例
lycorptech_jp
PRO
0
670
Aurora DSQLはサーバーレスアーキテクチャの常識を変えるのか
iwatatomoya
1
1.2k
Featured
See All Featured
[RailsConf 2023 Opening Keynote] The Magic of Rails
eileencodes
30
9.7k
Exploring the Power of Turbo Streams & Action Cable | RailsConf2023
kevinliebholz
34
6k
The Psychology of Web Performance [Beyond Tellerrand 2023]
tammyeverts
49
3k
Intergalactic Javascript Robots from Outer Space
tanoku
272
27k
No one is an island. Learnings from fostering a developers community.
thoeni
21
3.4k
Why Our Code Smells
bkeepers
PRO
339
57k
The Invisible Side of Design
smashingmag
301
51k
Designing Dashboards & Data Visualisations in Web Apps
destraynor
231
53k
Fashionably flexible responsive web design (full day workshop)
malarkey
407
66k
Imperfection Machines: The Place of Print at Facebook
scottboms
268
13k
Done Done
chrislema
185
16k
Git: the NoSQL Database
bkeepers
PRO
431
66k
Transcript
#tdd @wecodeio @luke_ar
Expectativas • 1:30 horas • 27 diapositivas • 1 demostración
en vivo* • código simple, en Java * “en vivo”, significa que puede fallar :)
¿Testing?
None
None
None
None
@Test public void prueba(){ assertEquals(5, sumar(2, 3)); }
@Test public void prueba(){ assertEquals(5, sumar(2, 3)); } sumar() assertEquals
2 3 ? 5
Test Driven Development
@Test public void prueba(){ assertEquals(5, sumar(2, 3)); }
@Test public void prueba(){ assertEquals(5, sumar(2, 3)); }
@Test public void prueba(){ assertEquals(5, sumar(2, 3)); }
@Test public void prueba(){ assertEquals(5, sumar(2, 3)); }
El Mantra
El Mantra mínimo código nueva prueba mejoras de diseño
demostración factores primos
¿Dónde está la magia? • Ciclos cortos • No es
sólo sobre las pruebas • Pruebas → diseño
Reglas de oro • Nunca se escribe una nueva funcionalidad
si hay algún test que falla. • Nunca se escribe código si no hay un test que evidencie su ausencia. • No se debe escribir más código del necesario para hacer pasar la prueba.
Refactoring • Cambiar estructura sin cambiar comportamiento. • Remueve duplicación.
• Vuelve el código más simple. • Vuelve el código más legible. • Se debe aplicar tanto al código productivo como a las pruebas.
¿Por qué no le gusta a la industria? • Tiempos
• Tiempos • Tiempos • Tiempos
TDD no es hace magia • No deriva arquitectura: deriva
diseño local • Se necesita una visión de arquitectura, aunque se valide con TDD • No es necesario ser miope
Consejos • Siempre tener una lista junto al teclado para
anotar los casos que se nos ocurran extemporáneamente. • Practicar con pequeños ejemplos reales. • Practicar con problemas conocidos.
El secreto “A medida que los tests se vuelven más
específicos, el código se vuelve más genérico”
Recursos • TDD by example, de Kent Beck http://amzn.to/1k24MZ7 •
Roman Numerals Kata, de Jim Weirich http://youtu.be/983zk0eqYLY • http://codekata.com/ • https://github.com/garora/TDD-Katas
¿Preguntas?
Gracias :) @wecodeio @luke_ar