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
Testing, automatización y otros secretos contra...
Search
Sponsored
·
Ship Features Fearlessly
Turn features on and off without deploys. Used by thousands of Ruby developers.
→
Jano González
October 27, 2012
Programming
860
2
Share
Testing, automatización y otros secretos contra el dolor de cabeza
Presentación para el Encuentro Linux 2012
Jano González
October 27, 2012
More Decks by Jano González
See All by Jano González
Containerizing your monolith
janogonzalez
0
480
Migrando a Microservicios
janogonzalez
1
330
Extracting services from a monolith
janogonzalez
3
280
¿Después de 10 años, realmente entiendo esta industria?
janogonzalez
3
510
Microservices in Practice
janogonzalez
7
710
Two programmers in one
janogonzalez
1
220
The Bipolar Programmer
janogonzalez
4
640
Ruby for your two internal programmers
janogonzalez
4
290
Ruby for Java minds
janogonzalez
4
1.1k
Other Decks in Programming
See All in Programming
ローカルで稼働するAI エージェントを超えて / beyond-local-ai-agents
gawa
1
230
The Past, Present, and Future of Enterprise Java
ivargrimstad
0
1.3k
forteeの改修から振り返るPHPerKaigi 2026
muno92
PRO
3
120
条件判定に名前、つけてますか? #phperkaigi #c
77web
2
910
今こそ押さえておきたい アマゾンウェブサービス(AWS)の データベースの基礎 おもクラ #6版
satoshi256kbyte
1
230
Rethinking API Platform Filters
vinceamstoutz
0
5.2k
車輪の再発明をしよう!PHP で実装して学ぶ、Web サーバーの仕組みと HTTP の正体
h1r0
2
480
AI時代のシステム設計:ドメインモデルで変更しやすさを守る設計戦略
masuda220
PRO
6
1.2k
Coding as Prompting Since 2025
ragingwind
0
640
今からFlash開発できるわけないじゃん、ムリムリ! (※ムリじゃなかった!?)
arkw
0
180
Cyrius ーLinux非依存にコンテナをネイティブ実行する専用OSー
n4mlz
0
270
メッセージングを利用して時間的結合を分離しよう #phperkaigi
kajitack
3
540
Featured
See All Featured
Optimizing for Happiness
mojombo
378
71k
The AI Revolution Will Not Be Monopolized: How open-source beats economies of scale, even for LLMs
inesmontani
PRO
3
3.2k
ラッコキーワード サービス紹介資料
rakko
1
2.9M
Paper Plane
katiecoart
PRO
1
48k
Why Your Marketing Sucks and What You Can Do About It - Sophie Logan
marketingsoph
0
120
sira's awesome portfolio website redesign presentation
elsirapls
0
200
実際に使うSQLの書き方 徹底解説 / pgcon21j-tutorial
soudai
PRO
199
73k
Typedesign – Prime Four
hannesfritz
42
3k
Design of three-dimensional binary manipulators for pick-and-place task avoiding obstacles (IECON2024)
konakalab
0
390
Building Experiences: Design Systems, User Experience, and Full Site Editing
marktimemedia
0
470
How to build an LLM SEO readiness audit: a practical framework
nmsamuel
1
700
ReactJS: Keep Simple. Everything can be a component!
pedronauck
666
130k
Transcript
testing, automatización y otros SECRETOS contra el dolor de cabeza
> el CHARLISTA
@janogonzalez
HopIn
@dynlangchile
> EL PROBLEMA
CH CH CH CHANGES
CAMBIO constante
CASTILLOS DE NAIPES
muchas tareas MANUALES
muchas tareas RUTINARIAS
propenso a ERRORES
SEÑALES DE HUMO
FEEDBACK TARDÍO
DOLOR DE CABEZA
PREVENIR ES MEJOR QUE CURAR
> CÓDIGO
APRENDE y USA LAS CONVECIONES
Ruby
Python
PHP
Java
> WTFM
Siempre CREA UN README
instrucciones para INSTALAR
UN EJEMPLO VALE MIL PALABRAS
DOCUMENTA CLASES y MÉTODOS
> BUILD
EL BUILD DEBE SER AUTOMÁTICO
make / rake / ant / etc...
> SCM
git
hg
svn
VERSIONA TODO
$ git init
$ git add README
$ git commit -m “Initial commit”
CREA COMMITS ATÓMICOS
$ git log --oneline 0e48171 Add password recovery to login
page 7b11d9b Create login page 69c32e9 Create project structure b543a0c Initial commit
usa buenos mensajes
$ git commit -m “Changes” ¡MAL!
$ git commit -m “Add password recovery in login” BIEN
$ git commit -m “CLOSE [84712] Add password recovery in
login” BIEN
USA bien LOS BRANCHES
$ git checkout -b password- recovery
$ git checkout -b wip-password- recovery
BRANCH PRINCIPAL DEPLOYABLE
USA LOS TAGS
$ git tag 1.0.0 -m “Initial release”
COMMIT EN FORMA TEMPRANA
PUSH EN FORMA TEMPRANA
> DEPENDENCIAS
MANEJO EN FORMA DECLARARTIVa
comportamiento predecible
<project> ... <dependencies> <dependency> <groupId>org.hibernate</groupId> <artifactId>hibernate-annotations</artifactId> </dependency> <dependency> <groupId>org.hibernate</groupId> <artifactId>hibernate</artifactId>
</dependency> </dependencies> ... </project> Maven
$ mvn clean install Maven
source 'https://rubygems.org' gem 'sinatra' gem 'json' gem 'sequel_pg', require: 'sequel'
gem 'koala' gem 'redis' gem 'mini_magick' gem 'aws-sdk' group :test do gem 'rack-test' end Bundler
$ bundle install Bundler
{ "require": { "monolog/monolog": "1.2.*" } } Composer
$ php composer.phar install Composer
> configuración
DATOS POR AMBIENTE
SEPARADO DEL ENTREGABLE
> TESTING
JUNIT / RSPEC / MOCHA / etc...
existen dos estrategias
UNITARIO / ACEPTACIÓN
PROBAR COMPONENTE AISLADO Unitario
CENTRADO en PROBAR UN FEATURE Aceptación
independiente
repetible
automatizado
> CI
Jenkins
CC
Travis
CREANDO BUILDS automáticos
Bajar código Compilar Ejecutar Pruebas Ejecutar Métricas Entregable
> DEPLOYMENT
cap
fab
CREANDO deploys automáticos
$ cap staging deploy cap
$ cap staging deploy:rollback cap
$ cap -s tag=1.0.0 production deploy cap
> Más ALLá
LEVANTAR AMBIENTES AUTOMÁTICAMENTE
> EJEMPLOS
> CONCLUSIONES
ACEPTA EL CAMBIO
AUTOMATIZA TODO LO QUe PUEDAS
OBTEN FEEDBACK TEMPRANO
Y SIEMPRE MEJORA
> ¡GRACIAS!
http://upload.wikimedia.org/wikipedia/commons/2/21/David_Bowie_Chile.jpg http://upload.wikimedia.org/wikipedia/commons/0/01/Card_castle6.JPG http://upload.wikimedia.org/wikipedia/commons/1/1c/Frederic_Remington_smoke_signal.jpg http://upload.wikimedia.org/wikipedia/commons/a/ad/Migraine.jpg