class TC_File
Attributes
logfile[R]
Public Instance Methods
create_fixture()
click to toggle source
# File test/test_file.rb, line 6 def create_fixture logfile = Pocolog::Logfiles.create('test') all_values = logfile.create_stream('all', 'int', 'test' => 'value', 'test2' => 'value2') 100.times do |i| all_values.write(Time.at(i), Time.at(i * 100), i) end logfile.close end
setup()
click to toggle source
# File test/test_file.rb, line 15 def setup create_fixture @logfile = Pocolog::Logfiles.open('test.0.log') end
teardown()
click to toggle source
# File test/test_file.rb, line 20 def teardown FileUtils.rm_f 'test.0.log' FileUtils.rm_f 'test.0.idx' end
test_has_stream()
click to toggle source
# File test/test_file.rb, line 25 def test_has_stream assert(logfile.has_stream?('all')) end