Make sure serialization works for projects

This commit is contained in:
Dave Halter
2020-01-31 02:14:34 +01:00
parent d09882f970
commit a05628443e
2 changed files with 25 additions and 7 deletions

View File

@@ -30,3 +30,11 @@ def test_added_sys_path(inference_state):
p = '/some_random_path'
project.added_sys_path = [p]
assert p in project._get_base_sys_path(inference_state)
def test_load_save_project(tmpdir):
project = Project(tmpdir.strpath, added_sys_path=['/foo'])
project.save()
loaded = Project.load(tmpdir.strpath)
assert loaded.added_sys_path == ['/foo']