Provide assert as an external method.
Removed the internal assert implementation from the engine and provide externally an assert function via api calls. JerryScript-DCO-1.0-Signed-off-by: Peter Gal pgal.u-szeged@partner.samsung.com
This commit is contained in:
@@ -19,6 +19,11 @@
|
||||
#include "test-common.h"
|
||||
|
||||
const char *test_source = (
|
||||
"function assert (arg) { "
|
||||
" if (!arg) { "
|
||||
" throw Error('Assert failed');"
|
||||
" } "
|
||||
"} "
|
||||
"this.t = 1; "
|
||||
"function f () { "
|
||||
"return this.t; "
|
||||
|
||||
Reference in New Issue
Block a user