wait 0.5 → 0.5.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- data/lib/loggers/base.rb +0 -4
- data/lib/rescuers/base.rb +6 -1
- data/lib/testers/base.rb +1 -1
- data/lib/version.rb +1 -1
- metadata +1 -1
data/lib/loggers/base.rb
CHANGED
data/lib/rescuers/base.rb
CHANGED
@@ -15,9 +15,14 @@ class Wait
|
|
15
15
|
# We can omit the message if it's identical to the class name.
|
16
16
|
message = exception.message unless exception.message == klass
|
17
17
|
# Indent the exception so it stands apart from the rest of the messages.
|
18
|
-
backtrace =
|
18
|
+
backtrace = indent(exception.backtrace)
|
19
19
|
|
20
20
|
@logger.debug("Rescuer") { "rescued: #{klass}#{": #{message}" if message}\n#{backtrace}" }
|
21
21
|
end
|
22
|
+
|
23
|
+
# Indents text a given number of spaces.
|
24
|
+
def indent(lines, spaces = 25)
|
25
|
+
lines.map { |line| (" " * spaces) + line }.join("\n")
|
26
|
+
end
|
22
27
|
end # BaseRescuer
|
23
28
|
end # Wait
|
data/lib/testers/base.rb
CHANGED
data/lib/version.rb
CHANGED