test/io_streams_test.rb in iostreams-1.2.1 vs test/io_streams_test.rb in iostreams-1.3.0
- old
+ new
@@ -14,11 +14,11 @@
let :expected_json do
records.collect(&:to_json).join("\n") + "\n"
end
let :json_file_name do
- "/tmp/io_streams/abc.json"
+ "/tmp/iostreams_abc.json"
end
describe ".root" do
it "return default path" do
path = ::File.expand_path(::File.join(__dir__, "../tmp/default"))
@@ -88,10 +88,10 @@
end
it "hash reader detects json format from file name" do
::File.open(json_file_name, "wb") { |file| file.write(expected_json) }
rows = []
- path = IOStreams.path("/tmp/io_streams/abc.json")
+ path = IOStreams.path(json_file_name)
path.each(:hash) do |row|
rows << row
end
actual = rows.collect(&:to_json).join("\n") + "\n"
path.delete