Skip to content
This repository was archived by the owner on Nov 30, 2024. It is now read-only.

Commit a62d1c9

Browse files
committed
Add spec for indented messages.
1 parent 16841a3 commit a62d1c9

File tree

1 file changed

+13
-0
lines changed

1 file changed

+13
-0
lines changed

spec/rspec/core/formatters/documentation_formatter_spec.rb

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -81,6 +81,19 @@ def execution_result(values)
8181
")
8282
end
8383

84+
it "can output indented messages" do
85+
root = RSpec.describe("root")
86+
root.example("example") {|example| example.reporter.message("message")}
87+
88+
root.run(reporter)
89+
90+
expect(formatter_output.string).to eql("
91+
root
92+
message
93+
example
94+
")
95+
end
96+
8497
it "strips whitespace for each row" do
8598
group = RSpec.describe(" root ")
8699
context1 = group.describe(" nested ")

0 commit comments

Comments
 (0)