diff options
| author | Jemma Issroff <jemmaissroff@gmail.com> | 2023-10-20 12:25:26 -0300 |
|---|---|---|
| committer | Jemma Issroff <jemmaissroff@gmail.com> | 2023-10-23 13:59:48 -0300 |
| commit | f9e122b3d65ec00cb501fd8d3df175c8453f261f (patch) | |
| tree | 0b2f502475c670553416e25217d5a473d9082ebe /test | |
| parent | 62c674f98cc74b4f1be1b909d69523f95bffe59f (diff) | |
[PRISM] Add several tests
Diffstat (limited to 'test')
| -rw-r--r-- | test/ruby/test_compile_prism.rb | 11 |
1 files changed, 6 insertions, 5 deletions
diff --git a/test/ruby/test_compile_prism.rb b/test/ruby/test_compile_prism.rb index 6b19abfe68..58744836b2 100644 --- a/test/ruby/test_compile_prism.rb +++ b/test/ruby/test_compile_prism.rb @@ -56,8 +56,10 @@ module Prism end def test_SourceLineNode - # TODO: - # test_prism_eval("__LINE__") + ruby_eval = RubyVM::InstructionSequence.compile_prism("__LINE__").eval + prism_eval = RubyVM::InstructionSequence.compile_prism("__LINE__").eval + + assert_equal ruby_eval, prism_eval end def test_TrueNode @@ -69,7 +71,7 @@ module Prism ############################################################################ def test_BackReferenceReadNode - # TOO + test_prism_eval("$+") end def test_ClassVariableReadNode @@ -538,8 +540,7 @@ module Prism end def test_SingletonClassNode - # TODO: - # test_prism_eval("class << self; end") + test_prism_eval("class << self; end") end def test_StatementsNode |
