spec/outputs/s3_spec.rb in logstash-output-s3-1.0.2 vs spec/outputs/s3_spec.rb in logstash-output-s3-2.0.0
- old
+ new
@@ -48,11 +48,11 @@
s3 = LogStash::Outputs::S3.new(config)
allow(s3).to receive(:test_s3_write)
s3.register
expect(Dir.exist?(temporary_directory)).to eq(true)
- s3.teardown
+ s3.close
FileUtils.rm_r(temporary_directory)
end
it "should raise a ConfigurationError if the prefix contains one or more '\^`><' characters" do
config = {
@@ -192,11 +192,11 @@
s3.tempfile = tmp
s3.register
end
after(:each) do
- s3.teardown
+ s3.close
tmp.close
tmp.unlink
end
it "raises no error when periodic rotation happen" do
@@ -326,10 +326,10 @@
until Time.now > stop_time do
s3.receive(event)
event_count += 1
end
- s3.teardown
+ s3.close
generated_files = Dir[File.join(temporary_directory, 'ls.*.txt')]
events_written_count = events_in_files(generated_files)