aboutsummaryrefslogtreecommitdiffstats
path: root/tests/test_integration.py
diff options
context:
space:
mode:
Diffstat (limited to 'tests/test_integration.py')
-rw-r--r--tests/test_integration.py21
1 files changed, 15 insertions, 6 deletions
diff --git a/tests/test_integration.py b/tests/test_integration.py
index 086abab..ba0d9b5 100644
--- a/tests/test_integration.py
+++ b/tests/test_integration.py
@@ -62,11 +62,15 @@ class IntegrationTests(unittest.TestCase):
"path": "main.py",
"content": b64encode_code(
"""
+ from pathlib import Path
from mod import lib
print(lib.var)
- with open('output.txt', 'w') as f:
- f.write('file write test')
+ with open('output/test.txt', 'w') as f:
+ f.write('test 1')
+
+ Path('output/dir').mkdir()
+ Path('output/dir/test2.txt').write_text('test 2')
"""
),
},
@@ -80,10 +84,15 @@ class IntegrationTests(unittest.TestCase):
"returncode": 0,
"files": [
{
- "path": "output.txt",
- "size": len("file write test"),
- "content": b64encode_code("file write test"),
- }
+ "path": "dir/test2.txt",
+ "size": len("test 2"),
+ "content": b64encode_code("test 2"),
+ },
+ {
+ "path": "test.txt",
+ "size": len("test 1"),
+ "content": b64encode_code("test 1"),
+ },
],
}