Project

General

Profile

« Previous | Next » 

Revision b0a97073

Added by eileencodes (Eileen Uchitelle) about 2 years ago

Use assert_prism_eval over test_prism_eval in helper

When we use test_prism_eval, failed tests will point to the line
number of the test_prism_eval method definition instead of the test
that failed. If we use assert_prism_eval instead, failed tests will
properly poin to the test that failed because the test framework knows
to stop the backtrace earlier.

Before line number in failure points to helper definition:

Prism::TestCompilePrism#test_RegularExpressionNode = 0.21 s 1) Failure: Prism::TestCompilePrism#test_RegularExpressionNode [test/ruby/test_compile_prism.rb:755]: </pit/> (Windows-31J) expected but was </pit/> (US-ASCII). 

After line number in failure points to test that failed:

Prism::TestCompilePrism#test_RegularExpressionNode = 0.00 s 1) Failure: Prism::TestCompilePrism#test_RegularExpressionNode [test/ruby/test_compile_prism.rb:334]: </pit/> (Windows-31J) expected but was </pit/> (US-ASCII).