Module: Snapsync::SelfTest
- Defined in:
- lib/snapsync/test.rb
Overview
This module is the common setup for all tests
Instance Method Summary collapse
Instance Method Details
#make_tmpdir ⇒ Object
48 49 50 |
# File 'lib/snapsync/test.rb', line 48 def make_tmpdir @tempdirs << Dir.mktmpdir end |
#setup ⇒ Object
32 33 34 35 36 37 38 |
# File 'lib/snapsync/test.rb', line 32 def setup @tempdirs = Array.new Snapsync._mountpointCache = {} Snapsync::Btrfs._mountpointCache = {} super # Setup code for all the tests end |
#teardown ⇒ Object
40 41 42 43 44 45 46 |
# File 'lib/snapsync/test.rb', line 40 def teardown @tempdirs.each do |dir| FileUtils.rm_rf dir end super # Teardown code for all the tests end |