aboutsummaryrefslogtreecommitdiffstats
path: root/test/erb
diff options
context:
space:
mode:
authorknu <knu@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2008-06-02 07:10:35 +0000
committerknu <knu@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2008-06-02 07:10:35 +0000
commit92623d3db8446d3033716af1ea85146a06b119ff (patch)
treeeb283439863169c049e919b30560bf4e69abf917 /test/erb
parentedcbe2ac457af9e1937544a2f5590d4fa691c5a6 (diff)
downloadruby-92623d3db8446d3033716af1ea85146a06b119ff.tar.gz
* lib/erb.rb (ERB::Compiler::TrimScanner#scan_line): Fix a bug
where tokens are not yilelded one by one. * test/erb/test_erb.rb (TestERBCore#_test_01) (TestERBCore#test_02_safe_04): The expected value should come first for assert_equal(). git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@16749 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'test/erb')
-rw-r--r--test/erb/test_erb.rb10
1 files changed, 5 insertions, 5 deletions
diff --git a/test/erb/test_erb.rb b/test/erb/test_erb.rb
index aac33863d4..ccd3ddb9fc 100644
--- a/test/erb/test_erb.rb
+++ b/test/erb/test_erb.rb
@@ -54,16 +54,16 @@ class TestERBCore < Test::Unit::TestCase
def _test_core(safe)
erb = @erb.new("hello")
- assert_equal(erb.result, "hello")
+ assert_equal("hello", erb.result)
erb = @erb.new("hello", safe, 0)
- assert_equal(erb.result, "hello")
+ assert_equal("hello", erb.result)
erb = @erb.new("hello", safe, 1)
- assert_equal(erb.result, "hello")
+ assert_equal("hello", erb.result)
erb = @erb.new("hello", safe, 2)
- assert_equal(erb.result, "hello")
+ assert_equal("hello", erb.result)
src = <<EOS
%% hi
@@ -159,7 +159,7 @@ EOS
def test_safe_04
erb = @erb.new('<%=$SAFE%>', 4)
- assert_equal(erb.result(TOPLEVEL_BINDING.taint), '4')
+ assert_equal('4', erb.result(TOPLEVEL_BINDING.taint))
end
class Foo; end