Espruino/tests/test_function_replacewith.js
Michael Duerinckx 7f5308590b Rename numbered tests to something more descriptive - closes #16
test077 is the only one I really couldn't figure out what it was meant
to test.
2014-03-01 22:15:28 +00:00

13 lines
217 B
JavaScript

// testing replaceWith functionality
var inner = function() {
var x = 5;
return function() { return x; }
}();
//trace(inner);
inner.replaceWith(function() { return x+2; });
//trace(inner);
result = inner()==7;