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
John Mettraux
November 29, 2018
Programming
0
280
tests and the database
making some tests faster by starting from test database dumps
John Mettraux
November 29, 2018
Tweet
Share
More Decks by John Mettraux
See All by John Mettraux
hiroshima.rb #70 pomodoro
jmettraux
0
330
OpenBSD and Ruby
jmettraux
1
600
Ruby and FFI
jmettraux
0
330
headless in Hiroshima.rb #061
jmettraux
0
280
Ruby methods in ect - Hiroshima.rb #058
jmettraux
0
1.2k
flor - hubristic interpreter - RubyKaigi 2017
jmettraux
1
1.4k
deli @ Hiroshima.rb #057
jmettraux
0
1.2k
suhi215 yahoo proxy in python
jmettraux
0
1.3k
chruby
jmettraux
0
530
Other Decks in Programming
See All in Programming
CSC307 Lecture 06
javiergs
PRO
0
360
小さな開発会社を作った理由
polidog
0
1.9k
AWSでゲームサーバーを運用! Amazon GameLiftのお話
iriikeita
0
200
Terraformテスト入門
msato
0
520
From Spring Boot 2 to Spring Boot 3 with Java 22 and Jakarta EE
ivargrimstad
0
1.9k
12年前の『型システム入門』翻訳の思い出話
mame
11
1.2k
CSC307 Lecture 13
javiergs
PRO
0
150
Composing an API the *right* way (Droidcon Berlin 2024)
zsmb
1
450
Polarsの成長: v0.14からv1.0までの変遷と今後の展望
zerebom
1
350
Folding Cheat Sheet #7
philipschwarz
PRO
0
150
Xcode 16のPreviewModifierと@Previewableを活用した効率的なプレビュー方法の考察
ojun9
2
160
SDCon2024: Enabling DevOps and Team Topologies thru architecture: architecting for fast flow
cer
PRO
0
780
Featured
See All Featured
Designing with Data
zakiwarfel
96
5k
Producing Creativity
orderedlist
PRO
340
39k
Why Our Code Smells
bkeepers
PRO
332
56k
The Power of CSS Pseudo Elements
geoffreycrofte
64
5.2k
ピンチをチャンスに:未来をつくるプロダクトロードマップ #pmconf2020
aki_iinuma
90
47k
It's Worth the Effort
3n
181
27k
Clear Off the Table
cherdarchuk
89
320k
RailsConf & Balkan Ruby 2019: The Past, Present, and Future of Rails at GitHub
eileencodes
129
32k
CSS Pre-Processors: Stylus, Less & Sass
bermonpainter
353
29k
YesSQL, Process and Tooling at Scale
rocio
166
14k
Building Adaptive Systems
keathley
34
2k
Sharpening the Axe: The Primacy of Toolmaking
bcantrill
26
1.6k
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