summaryrefslogtreecommitdiff
path: root/spec/ruby/library/pp/pp_spec.rb
diff options
context:
space:
mode:
Diffstat (limited to 'spec/ruby/library/pp/pp_spec.rb')
-rw-r--r--spec/ruby/library/pp/pp_spec.rb7
1 files changed, 7 insertions, 0 deletions
diff --git a/spec/ruby/library/pp/pp_spec.rb b/spec/ruby/library/pp/pp_spec.rb
index 06b22601d8..243478efd9 100644
--- a/spec/ruby/library/pp/pp_spec.rb
+++ b/spec/ruby/library/pp/pp_spec.rb
@@ -20,4 +20,11 @@ describe "PP.pp" do
other_out.to_s.should == "[1, 2, 3]\n"
end
+
+ it 'correctly prints a Hash' do
+ hash = { 'key' => 42 }
+ -> {
+ PP.pp hash
+ }.should output('{"key"=>42}' + "\n")
+ end
end