aboutsummaryrefslogtreecommitdiffstats
path: root/Library/Homebrew/test/test_string.rb
diff options
context:
space:
mode:
authorMichael Morgan2010-10-17 18:27:10 -0400
committerAdam Vandenberg2010-10-17 21:13:16 -0700
commit447fb2f6401bc642e3074efaeb664f8cb9338118 (patch)
tree0df57cedfb427f928fb238202763cf45bd3f3c7f /Library/Homebrew/test/test_string.rb
parentbb32c7e6885f11643c2255a1a97ae331a17339e3 (diff)
downloadhomebrew-447fb2f6401bc642e3074efaeb664f8cb9338118.tar.bz2
extract undent test to test case
Signed-off-by: Adam Vandenberg <flangy@gmail.com>
Diffstat (limited to 'Library/Homebrew/test/test_string.rb')
-rw-r--r--Library/Homebrew/test/test_string.rb15
1 files changed, 15 insertions, 0 deletions
diff --git a/Library/Homebrew/test/test_string.rb b/Library/Homebrew/test/test_string.rb
new file mode 100644
index 000000000..55a70f72c
--- /dev/null
+++ b/Library/Homebrew/test/test_string.rb
@@ -0,0 +1,15 @@
+require 'testing_env'
+require 'utils'
+
+require 'extend/string'
+
+class StringTest <Test::Unit::TestCase
+ def test_undent
+ undented = <<-EOS.undent
+ hi
+....my friend over
+ there
+ EOS
+ assert undented == "hi\nmy friend over\nthere\n"
+ end
+end