aboutsummaryrefslogtreecommitdiff
path: root/tests/runner.py
diff options
context:
space:
mode:
authorAlon Zakai <azakai@mozilla.com>2010-11-06 11:48:23 -0700
committerAlon Zakai <azakai@mozilla.com>2010-11-06 11:48:23 -0700
commit38cf88b3607066a9fa1d3f7ca0518e2bc9844ff6 (patch)
tree9922c65c3a96701ae0a591535990f8bab5cbd67c /tests/runner.py
parent906a8745c2a70d3bf797bce28c5c0ba055f8b98a (diff)
working integration test
Diffstat (limited to 'tests/runner.py')
-rw-r--r--tests/runner.py9
1 files changed, 7 insertions, 2 deletions
diff --git a/tests/runner.py b/tests/runner.py
index 407a9c57..f84be41a 100644
--- a/tests/runner.py
+++ b/tests/runner.py
@@ -1010,14 +1010,19 @@ if 'benchmark' not in sys.argv:
int ScriptMe::mulVal(int mul) { value *= mul; }
'''
script_src = '''
- // TODO
+ var sme = Scriptable.ScriptMe.__alloc__();
+ Scriptable.ScriptMe.ScriptMe(sme, 83);
+ Scriptable.ScriptMe.mulVal(sme, 2);
+ print('*' + Scriptable.ScriptMe.getVal(sme) + '*');
+ _free(sme);
+ print('*ok*');
'''
def post(filename):
Popen(['python', DEMANGLER, filename, '.'], stdout=open(filename + '.tmp', 'w')).communicate()
Popen(['python', NAMESPACER, filename + '.tmp'], stdout=open(filename + '.tmp2', 'w')).communicate()
src = open(filename, 'r').read() + 'var Scriptable = ' + open(filename + '.tmp2', 'r').read().rstrip() + ';\n\n' + script_src
open(filename, 'w').write(src)
- self.do_test(src, '', post_build=post)
+ self.do_test(src, '*166*\n*ok*', post_build=post)
# Generate tests for all our compilers
def make_test(compiler, embetter):