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
320
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
380
OpenBSD and Ruby
jmettraux
1
680
Ruby and FFI
jmettraux
0
370
headless in Hiroshima.rb #061
jmettraux
0
340
Ruby methods in ect - Hiroshima.rb #058
jmettraux
0
1.4k
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
590
Other Decks in Programming
See All in Programming
GoとPHPのインターフェイスの違い
shimabox
2
190
苦しいTiDBへの移行を乗り越えて快適な運用を目指す
leveragestech
0
640
Formの複雑さに立ち向かう
bmthd
1
860
AIの力でお手軽Chrome拡張機能作り
taiseiue
0
170
DROBEの生成AI活用事例 with AWS
ippey
0
130
Linux && Docker 研修/Linux && Docker training
forrep
24
4.5k
コミュニティ駆動 AWS CDK ライブラリ「Open Constructs Library」 / community-cdk-library
gotok365
2
140
定理証明プラットフォーム lapisla.net
abap34
1
1.8k
Grafana Cloudとソラカメ
devoc
0
170
ML.NETで始める機械学習
ymd65536
0
100
Multi Step Form, Decentralized Autonomous Organization
pumpkiinbell
1
750
Immutable ActiveRecord
megane42
0
140
Featured
See All Featured
Code Review Best Practice
trishagee
67
18k
How STYLIGHT went responsive
nonsquared
98
5.4k
Thoughts on Productivity
jonyablonski
69
4.5k
What's in a price? How to price your products and services
michaelherold
244
12k
jQuery: Nuts, Bolts and Bling
dougneiner
63
7.6k
Building Your Own Lightsaber
phodgson
104
6.2k
Build The Right Thing And Hit Your Dates
maggiecrowley
34
2.5k
Embracing the Ebb and Flow
colly
84
4.6k
Helping Users Find Their Own Way: Creating Modern Search Experiences
danielanewman
29
2.4k
Refactoring Trust on Your Teams (GOTO; Chicago 2020)
rmw
33
2.8k
10 Git Anti Patterns You Should be Aware of
lemiorhan
PRO
656
59k
Unsuck your backbone
ammeep
669
57k
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