Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Browse files

Better error messages for some of ActiveSupport tests

[#4635 state:resolved]

Signed-off-by: José Valim <jose.valim@gmail.com>
  • Loading branch information...
commit 0dab076a08110b87aacc27e2ce5a20173b3d458d 1 parent c00f8e4
@neerajdotname neerajdotname authored josevalim committed
Showing with 6 additions and 6 deletions.
  1. +6 −6 activesupport/test/buffered_logger_test.rb
View
12 activesupport/test/buffered_logger_test.rb
@@ -69,11 +69,11 @@ def test_should_not_mutate_message
4.times do
@logger.info 'wait for it..'
- assert @output.string.empty?, @output.string
+ assert @output.string.empty?, "@output.string should be empty but it is #{@output.string}"
end
@logger.flush
- assert !@output.string.empty?, @logger.send(:buffer).size.to_s
+ assert !@output.string.empty?, "@logger.send(:buffer).size.to_s should not be empty but it is empty"
end
define_method "test_disabling_auto_flush_with_#{disable.inspect}_should_flush_at_max_buffer_size_as_failsafe" do
@@ -82,11 +82,11 @@ def test_should_not_mutate_message
(Logger::MAX_BUFFER_SIZE - 1).times do
@logger.info 'wait for it..'
- assert @output.string.empty?, @output.string
+ assert @output.string.empty?, "@output.string should be empty but is #{@output.string}"
end
@logger.info 'there it is.'
- assert !@output.string.empty?, @logger.send(:buffer).size.to_s
+ assert !@output.string.empty?, "@logger.send(:buffer).size.to_s should not be empty but it is empty"
end
end
@@ -102,11 +102,11 @@ def test_should_auto_flush_every_n_messages
4.times do
@logger.info 'wait for it..'
- assert @output.string.empty?, @output.string
+ assert @output.string.empty?, "@output.string should be empty but it is #{@output.string}"
end
@logger.info 'there it is.'
- assert !@output.string.empty?, @output.string
+ assert !@output.string.empty?, "@output.string should not be empty but it is empty"
end
def test_should_create_the_log_directory_if_it_doesnt_exist
Please sign in to comment.
Something went wrong with that request. Please try again.