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
340
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
400
OpenBSD and Ruby
jmettraux
1
720
Ruby and FFI
jmettraux
0
390
headless in Hiroshima.rb #061
jmettraux
0
360
Ruby methods in ect - Hiroshima.rb #058
jmettraux
0
1.5k
flor - hubristic interpreter - RubyKaigi 2017
jmettraux
1
1.7k
deli @ Hiroshima.rb #057
jmettraux
0
1.4k
suhi215 yahoo proxy in python
jmettraux
0
1.6k
chruby
jmettraux
0
620
Other Decks in Programming
See All in Programming
既存デザインを変更せずにタップ領域を広げる方法
tahia910
1
240
LINEヤフー データグループ紹介
lycorp_recruit_jp
0
760
イベントストーミングから始めるドメイン駆動設計
jgeem
4
870
セキュリティマネジャー廃止とクラウドネイティブ型サンドボックス活用
kazumura
1
190
データベースコネクションプール(DBCP)の変遷と理解
fujikawa8
1
270
Benchmark
sysong
0
230
Spring gRPC で始める gRPC 入門 / Introduction to gRPC with Spring gRPC
mackey0225
2
520
Effect の双対、Coeffect
yukikurage
5
1.4k
プロダクト開発でも使おう 関数のオーバーロード
yoiwamoto
0
160
DroidKnights 2025 - 다양한 스크롤 뷰에서의 영상 재생
gaeun5744
3
300
A2A プロトコルを試してみる
azukiazusa1
2
790
Elixir で IoT 開発、 Nerves なら簡単にできる!?
pojiro
1
150
Featured
See All Featured
Into the Great Unknown - MozCon
thekraken
39
1.9k
BBQ
matthewcrist
89
9.7k
Responsive Adventures: Dirty Tricks From The Dark Corners of Front-End
smashingmag
252
21k
A better future with KSS
kneath
239
17k
For a Future-Friendly Web
brad_frost
179
9.8k
Producing Creativity
orderedlist
PRO
346
40k
Agile that works and the tools we love
rasmusluckow
329
21k
A Modern Web Designer's Workflow
chriscoyier
693
190k
VelocityConf: Rendering Performance Case Studies
addyosmani
330
24k
Why You Should Never Use an ORM
jnunemaker
PRO
56
9.4k
Navigating Team Friction
lara
187
15k
Rebuilding a faster, lazier Slack
samanthasiow
81
9k
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