Permalink
Browse files

Pass when assert returns a false value

  • Loading branch information...
syucream committed Jan 7, 2017
1 parent 392d7fb commit f085baae06c967e829d463a8156fa9c3be4e0330
Showing with 2 additions and 1 deletion.
  1. +2 −1 test/assert.rb
View
@@ -44,7 +44,8 @@ def assert(str = 'Assertion failed', iso = '')
begin
$mrbtest_assert = []
$mrbtest_assert_idx = 0
if(!yield || $mrbtest_assert.size > 0)
yield
if($mrbtest_assert.size > 0)
$asserts.push(assertion_string('Fail: ', str, iso, nil))
$ko_test += 1
t_print('F')

0 comments on commit f085baa

Please sign in to comment.