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
Testando aplicação phoenix
Search
Igor Florian
January 30, 2016
Programming
1
230
Testando aplicação phoenix
Igor Florian
January 30, 2016
Tweet
Share
More Decks by Igor Florian
See All by Igor Florian
Você não está sozinho, vá pra produção com Elixir!
igorffs
3
290
Conceitos que podem te ajudar a escrever testes melhores
igorffs
4
250
Other Decks in Programming
See All in Programming
CSC305 Summer Lecture 12
javiergs
PRO
0
130
もうちょっといいRubyプロファイラを作りたい (2025)
osyoyu
0
220
パッケージ設計の黒魔術/Kyoto.go#63
lufia
3
390
開発チーム・開発組織の設計改善スキルの向上
masuda220
PRO
18
9.6k
UbieのAIパートナーを支えるコンテキストエンジニアリング実践
syucream
2
800
兎に角、コードレビュー
mitohato14
0
160
🔨 小さなビルドシステムを作る
momeemt
2
630
LLMOpsのパフォーマンスを支える技術と現場で実践した改善
po3rin
8
1k
rage against annotate_predecessor
junk0612
0
150
AHC051解法紹介
eijirou
0
640
オープンセミナー2025@広島LT技術ブログを続けるには
satoshi256kbyte
0
150
Kiroの仕様駆動開発から見えてきたAIコーディングとの正しい付き合い方
clshinji
1
180
Featured
See All Featured
Build The Right Thing And Hit Your Dates
maggiecrowley
37
2.8k
A Tale of Four Properties
chriscoyier
160
23k
How to train your dragon (web standard)
notwaldorf
96
6.2k
VelocityConf: Rendering Performance Case Studies
addyosmani
332
24k
The Success of Rails: Ensuring Growth for the Next 100 Years
eileencodes
46
7.6k
Raft: Consensus for Rubyists
vanstee
140
7.1k
The Web Performance Landscape in 2024 [PerfNow 2024]
tammyeverts
9
790
Creating an realtime collaboration tool: Agile Flush - .NET Oxford
marcduiker
31
2.2k
Music & Morning Musume
bryan
46
6.8k
Why Our Code Smells
bkeepers
PRO
339
57k
The Straight Up "How To Draw Better" Workshop
denniskardys
236
140k
Become a Pro
speakerdeck
PRO
29
5.5k
Transcript
@igorflorianfs IGOR FLORIAN
TESTANDO SUA APLICAÇÃO WEB PHOENIX
ExUnit
http://elixir-lang.org/docs/stable/ex_unit/ExUnit.html
Channel
http://hexdocs.pm/phoenix/Phoenix.Channel.html
Overview
• Model • View & Template • Controller • Acceptance
• Fixture
✋
Nas camadas da aplicação você verá
None
web/web.ex
None
E nos testes…
None
Test Cases
None
None
None
None
MODEL
None
None
Foco nas validações
Changeset
None
None
None
https://hexdocs.pm/ecto/Ecto.Changeset.html
CONTROLLER
Características da conexão
None
None
Plug.Conn
None
https://hexdocs.pm/plug/Plug.Conn.html
None
None
VIEW & TEMPLATE
VIEWS == funções puras
None
None
TEMPLATES testamos diferente!
None
EEX
None
ACCEPTANCE
Hound
None
None
None
None
https://github.com/HashNuke/hound
Lembre-se, testes de aceitação são lentos
http://blog.plataformatec.com.br/2016/01/writing-acceptance-tests-in-phoenix/
Test Data
Ecto
None
ExMachina
FactoryGirl feelings
None
None
https://github.com/thoughtbot/ex_machina
Spoiler Ecto 2.0
None
None
None
https://github.com/elixir-lang/ecto
Obrigado!