summaryrefslogtreecommitdiff
path: root/test/test_pp.rb
diff options
context:
space:
mode:
Diffstat (limited to 'test/test_pp.rb')
-rw-r--r--test/test_pp.rb6
1 files changed, 3 insertions, 3 deletions
diff --git a/test/test_pp.rb b/test/test_pp.rb
index d0104651ea..4736bff149 100644
--- a/test/test_pp.rb
+++ b/test/test_pp.rb
@@ -196,9 +196,9 @@ end
class PPAbstractSyntaxTree < Test::Unit::TestCase
AST = RubyVM::AbstractSyntaxTree
- def test_literal
- ast = AST.parse("1")
- expected = "(SCOPE@1:0-1:1 tbl: [] args: nil body: (LIT@1:0-1:1 1))"
+ def test_lasgn_literal
+ ast = AST.parse("_=1")
+ expected = "(SCOPE@1:0-1:3 tbl: [:_] args: nil body: (LASGN@1:0-1:3 :_ (LIT@1:2-1:3 1)))"
assert_equal(expected, PP.singleline_pp(ast, ''.dup), ast)
end
end