diff options
author | Vasilis Kalintiris <ehostunreach@gmail.com> | 2013-12-07 16:32:46 +0200 |
---|---|---|
committer | Vasilis Kalintiris <ehostunreach@gmail.com> | 2013-12-07 19:36:01 +0200 |
commit | a690aeeddc70c51b814999ec8c3d2093e85ed647 (patch) | |
tree | 4862c9d48737150b0948277f0db3fca6caa4fcaa /tests/test_core.py | |
parent | 75410f1c96a9216a2b597efec1a6128b3bc7c826 (diff) |
Use do_run_from_file() for test_direct_string_constant_usage
Diffstat (limited to 'tests/test_core.py')
-rw-r--r-- | tests/test_core.py | 18 |
1 files changed, 4 insertions, 14 deletions
diff --git a/tests/test_core.py b/tests/test_core.py index f3b036eb..2292676a 100644 --- a/tests/test_core.py +++ b/tests/test_core.py @@ -4020,20 +4020,10 @@ def process(filename): def test_direct_string_constant_usage(self): if self.emcc_args is None: return self.skip('requires libcxx') - src = ''' - #include <iostream> - template<int i> - void printText( const char (&text)[ i ] ) - { - std::cout << text; - } - int main() - { - printText( "some string constant" ); - return 0; - } - ''' - self.do_run(src, "some string constant") + test_path = path_from_root('tests', 'core', 'test_direct_string_constant_usage') + src, output = (test_path + s for s in ('.in', '.out')) + + self.do_run_from_file(src, output) def test_std_cout_new(self): if self.emcc_args is None: return self.skip('requires emcc') |