Skip to content

Commit

Permalink
fixup! Add Nanoc::Int::Store.tmp_path_for test
Browse files Browse the repository at this point in the history
  • Loading branch information
barraq committed Jun 19, 2016
1 parent 4884586 commit 4a29948
Showing 1 changed file with 12 additions and 0 deletions.
12 changes: 12 additions & 0 deletions test/base/test_store.rb
Expand Up @@ -32,4 +32,16 @@ def test_delete_and_reload_on_error
store.load
assert_equal(nil, store.data)
end

def test_tmp_path_with_nil_env
tmp_path_for_checksum = Nanoc::Int::Store.tmp_path_for(nil, 'checksum')
assert_equal('tmp/checksum', tmp_path_for_checksum)
end

def test_tmp_path_with_test_env
tmp_path_for_checksum = Nanoc::Int::Store.tmp_path_for('test', 'checksum')
tmp_path_for_dependencies = Nanoc::Int::Store.tmp_path_for(:test, 'dependencies')
assert_equal('tmp/test/checksum', tmp_path_for_checksum)
assert_equal('tmp/test/dependencies', tmp_path_for_dependencies)
end
end

0 comments on commit 4a29948

Please sign in to comment.