diff options
author | Vasilis Kalintiris <ehostunreach@gmail.com> | 2013-12-07 16:36:53 +0200 |
---|---|---|
committer | Vasilis Kalintiris <ehostunreach@gmail.com> | 2013-12-07 19:36:01 +0200 |
commit | 776b12fc811e38907bcca064c2ffc4c221794e94 (patch) | |
tree | 6721dbee00929096df23c0fc936bdb2966607092 /tests/test_core.py | |
parent | 8c60ac77238f3b514d4603af9014c48b067b0a05 (diff) |
Use do_run_from_file() for test_istream
Diffstat (limited to 'tests/test_core.py')
-rw-r--r-- | tests/test_core.py | 19 |
1 files changed, 3 insertions, 16 deletions
diff --git a/tests/test_core.py b/tests/test_core.py index 5fe627c5..b3f3fa2c 100644 --- a/tests/test_core.py +++ b/tests/test_core.py @@ -4036,26 +4036,13 @@ def process(filename): def test_istream(self): if self.emcc_args is None: return self.skip('requires libcxx') - src = ''' - #include <string> - #include <sstream> - #include <iostream> - - int main() - { - std::string mystring("1 2 3"); - std::istringstream is(mystring); - int one, two, three; - - is >> one >> two >> three; + test_path = path_from_root('tests', 'core', 'test_istream') + src, output = (test_path + s for s in ('.in', '.out')) - printf( "%i %i %i", one, two, three ); - } - ''' for linkable in [0]:#, 1]: print linkable Settings.LINKABLE = linkable # regression check for issue #273 - self.do_run(src, "1 2 3") + self.do_run_from_file(src, output) def test_fs_base(self): Settings.INCLUDE_FULL_LIBRARY = 1 |