diff options
author | knu <knu@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2008-06-02 07:10:35 +0000 |
---|---|---|
committer | knu <knu@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2008-06-02 07:10:35 +0000 |
commit | 16d65fd118e9053bb0b2ff3f958f3c6509c2ac38 (patch) | |
tree | eb283439863169c049e919b30560bf4e69abf917 /test/erb | |
parent | 51e8934abdad232a5fd921a55a1c07b695abb8ba (diff) | |
download | ruby-16d65fd118e9053bb0b2ff3f958f3c6509c2ac38.tar.gz ruby-16d65fd118e9053bb0b2ff3f958f3c6509c2ac38.tar.xz ruby-16d65fd118e9053bb0b2ff3f958f3c6509c2ac38.zip |
* 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: http://svn.ruby-lang.org/repos/ruby/trunk@16749 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'test/erb')
-rw-r--r-- | test/erb/test_erb.rb | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/test/erb/test_erb.rb b/test/erb/test_erb.rb index aac33863d..ccd3ddb9f 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 |