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
tests and the database
Search
Sponsored
·
Ship Features Fearlessly
Turn features on and off without deploys. Used by thousands of Ruby developers.
→
John Mettraux
November 29, 2018
Programming
400
0
Share
tests and the database
making some tests faster by starting from test database dumps
John Mettraux
November 29, 2018
More Decks by John Mettraux
See All by John Mettraux
hiroshima.rb #70 pomodoro
jmettraux
0
450
OpenBSD and Ruby
jmettraux
1
820
Ruby and FFI
jmettraux
0
440
headless in Hiroshima.rb #061
jmettraux
0
410
Ruby methods in ect - Hiroshima.rb #058
jmettraux
0
1.7k
flor - hubristic interpreter - RubyKaigi 2017
jmettraux
1
1.9k
deli @ Hiroshima.rb #057
jmettraux
0
1.6k
suhi215 yahoo proxy in python
jmettraux
0
1.9k
chruby
jmettraux
0
690
Other Decks in Programming
See All in Programming
inferと仲良くなる10分間
ryokatsuse
1
370
Technical Debt: Understanding it Rightly, Engaging it Rightly #LaravelLiveJP
shogogg
0
190
jQueryをバージョンアップする前に使いたいjQuery Migrate
matsuo_atsushi
0
180
Inside Stream API
skrb
1
630
net-httpのHTTP/2対応について
naruse
0
440
dRuby over BLE
makicamel
2
300
3Dシーンの圧縮
fadis
1
600
Old Dog, New Tricks: The Java 25 Reinvention - JNation
bazlur_rahman
0
140
Lessons from Spec-Driven Development
simas
PRO
0
140
AIエージェントと協働するCLI開発 — BunとOpenClawで学んだこと
yoshikouki
1
230
Why Laravel apps break—Mastering the fundamentals to keep them maintainable
kentaroutakeda
1
340
Lemonade + Foundry Toolkit でお手軽アプリ開発
seosoft
1
290
Featured
See All Featured
Raft: Consensus for Rubyists
vanstee
141
7.5k
Measuring Dark Social's Impact On Conversion and Attribution
stephenakadiri
2
210
世界の人気アプリ100個を分析して見えたペイウォール設計の心得
akihiro_kokubo
PRO
71
40k
Being A Developer After 40
akosma
91
590k
コードの90%をAIが書く世界で何が待っているのか / What awaits us in a world where 90% of the code is written by AI
rkaga
61
44k
Performance Is Good for Brains [We Love Speed 2024]
tammyeverts
12
1.7k
Making the Leap to Tech Lead
cromwellryan
135
9.9k
Ethics towards AI in product and experience design
skipperchong
2
300
Documentation Writing (for coders)
carmenintech
77
5.4k
Building a A Zero-Code AI SEO Workflow
portentint
PRO
0
550
Navigating Algorithm Shifts & AI Overviews - #SMXNext
aleyda
1
1.3k
Music & Morning Musume
bryan
47
7.2k
Transcript
None
tests and the database
hiro shima .rb #67 • Sinatra • Sequel • JRuby
hiro shima .rb #67
hiro shima .rb #67
hiro shima .rb #67 took 20s.
hiro shima .rb #67 took 20s.
hiro shima .rb #67 bxs spec/functional/models/sg_mandate_spec.rb:210 bxs spec/functional/models/sg_mandate_spec.rb -e fubar
bxs spec/functional/models/sg_mandate_spec.rb bxs spec/functional/models/ alias bxs=“bundle exec rspec” bxs
hiro shima .rb #67 bxs spec/functional/models/sg_mandate_spec.rb:210 bxs spec/functional/models/sg_mandate_spec.rb -e fubar
bxs spec/functional/models/sg_mandate_spec.rb bxs spec/functional/models/ alias bxs=“bundle exec rspec” bxs 30s to 2m 20m to 30m
hiro shima .rb #67 bxs spec/functional/models/sg_mandate_spec.rb:210 bxs spec/functional/models/sg_mandate_spec.rb -e fubar
bxs spec/functional/models/sg_mandate_spec.rb bxs spec/functional/models/ alias bxs=“bundle exec rspec” bxs focus control
hiro shima .rb #67 bxs spec/functional/models/sg_mandate_spec.rb:210 bxs spec/functional/models/sg_mandate_spec.rb -e fubar
bxs spec/functional/models/sg_mandate_spec.rb bxs spec/functional/models/ alias bxs=“bundle exec rspec” bxs focus control
hiro shima .rb #67 bxs spec/functional/models/sg_mandate_spec.rb:210 bxs spec/functional/models/sg_mandate_spec.rb -e fubar
bxs spec/functional/models/sg_mandate_spec.rb bxs spec/functional/models/ alias bxs=“bundle exec rspec” bxs focus control unit (no db access) functional (no browser) integration (selenium)
hiro shima .rb #67
hiro shima .rb #67
hiro shima .rb #67 what if we had a dump
of the test database, right after load_integration_fixtures() ?
hiro shima .rb #67 what if we had a dump
of the test database, right after load_integration_fixtures() ?
hiro shima .rb #67 what if we had a dump
of the test database, right after load_integration_fixtures() ?
hiro shima .rb #67 what if we had a dump
of the test database, right after load_integration_fixtures() ?
hiro shima .rb #67 what if we had a dump
of the test database, right after load_integration_fixtures() ? dump: 0.2s dump: 61M load: 1.8s
hiro shima .rb #67
hiro shima .rb #67
hiro shima .rb #67
hiro shima .rb #67
hiro shima .rb #67 still 20s cost remains
hiro shima .rb #67 still 20s cost remains
hiro shima .rb #67 still 20s cost remains
hiro shima .rb #67 still 20s cost remains
hiro shima .rb #67 still 20s cost remains
hiro shima .rb #67
hiro shima .rb #67
hiro shima .rb #67 the end