Updated RubySpec source to 55122684.
[rbx.git] / spec / frozen / 1.8 / library / cgi / pretty_spec.rb
blobba7471d61f9b3e6038374dfce2a2f8194cfedcb1
1 require File.dirname(__FILE__) + '/../../spec_helper'
2 require 'cgi'
4 describe "CGI.pretty when passed html" do
5   it "indents the passed html String with two spaces" do
6     CGI.pretty("<HTML><BODY></BODY></HTML>").should == <<-EOS
7 <HTML>
8   <BODY>
9   </BODY>
10 </HTML>
11 EOS
12   end
13 end
15 describe "CGI.pretty when passed html, indentation_unit" do
16   it "indents the passed html String with the passed indentation_unit" do
17     CGI.pretty("<HTML><BODY></BODY></HTML>", "\t").should == <<-EOS
18 <HTML>
19 \t<BODY>
20 \t</BODY>
21 </HTML>
22 EOS
23   end
24 end