Skip to content

Commit 701dbf9

Browse files
author
Franziska Geiger
committed
Started implementing test case
1 parent 6766feb commit 701dbf9

File tree

1 file changed

+10
-0
lines changed

1 file changed

+10
-0
lines changed

graalpython/com.oracle.graal.python.test/src/tests/test_posix.py

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -51,3 +51,13 @@ def test_uname(self):
5151
self.assertIsNotNone(uname.release)
5252
self.assertIsNotNone(uname.version)
5353
self.assertIsNotNone(uname.machine)
54+
55+
def test_execv(self, tmpdir):
56+
print tmpdir
57+
58+
sub = tmpdir.mkdir("sub")
59+
sub.join("testfile.sh").write("echo \"something echo\" > {}/sub/test.txt".format(tmpdir))
60+
import os
61+
toExecute = tmpdir + '/testfile.sh'
62+
os.execv(toExecute, [toExecute])
63+
assert os.path.isfile(tmpdir + '/sub/test.txt')

0 commit comments

Comments
 (0)