diff --git a/lib/docs/core/manifest.rb b/lib/docs/core/manifest.rb index cc7ff49f..624d2b81 100644 --- a/lib/docs/core/manifest.rb +++ b/lib/docs/core/manifest.rb @@ -21,7 +21,7 @@ module Docs end def to_json - JSON.generate(as_json) + JSON.pretty_generate(as_json) end end end diff --git a/test/lib/docs/core/manifest_test.rb b/test/lib/docs/core/manifest_test.rb index 56c9d416..16484a70 100644 --- a/test/lib/docs/core/manifest_test.rb +++ b/test/lib/docs/core/manifest_test.rb @@ -78,7 +78,7 @@ class ManifestTest < MiniTest::Spec describe "#to_json" do it "returns the JSON string for #as_json" do stub(manifest).as_json { { test: 'ok' } } - assert_equal '{"test":"ok"}', manifest.to_json + assert_equal "{\n \"test\": \"ok\"\n}", manifest.to_json end end end