2019-10-12 23:23:16 +08:00
|
|
|
# frozen_string_literal: true
|
2022-01-13 17:05:07 +08:00
|
|
|
|
|
|
|
|
require("test_helper")
|
2019-06-14 14:11:27 +08:00
|
|
|
|
|
|
|
|
class HelperTest < MiniTest::Test
|
|
|
|
|
include(TmpdirHelper)
|
|
|
|
|
|
|
|
|
|
def test_validate_cache_path
|
2022-01-13 17:05:07 +08:00
|
|
|
path = Help.set_file("a.rb", "a = a = 3", 100)
|
2019-06-14 14:11:27 +08:00
|
|
|
cp = Help.cache_path(@tmp_dir, path)
|
|
|
|
|
load(path)
|
|
|
|
|
assert_equal(true, File.file?(cp))
|
|
|
|
|
end
|
|
|
|
|
end
|