From 107857f2832d5f05e1a61dd21665880b865e1f94 Mon Sep 17 00:00:00 2001 From: thalassemia <67928790+thalassemia@users.noreply.github.com> Date: Tue, 21 May 2024 19:14:41 -0700 Subject: [PATCH] Fix PYTHONPATH for variant test --- scripts/create_variants.py | 3 +++ 1 file changed, 3 insertions(+) diff --git a/scripts/create_variants.py b/scripts/create_variants.py index 42e8c9301..a4c55c4d5 100644 --- a/scripts/create_variants.py +++ b/scripts/create_variants.py @@ -188,7 +188,9 @@ def test_create_variants(): # Create mock sim_data pickle with open("test_create_variants/kb/simData.cPickle", "wb") as f: pickle.dump(SimData(), f) + repo_dir = os.path.dirname(os.path.dirname(__file__)) # Test script and config system + os.environ['PYTHONPATH'] = repo_dir subprocess.run( [ "python", @@ -201,6 +203,7 @@ def test_create_variants(): "test_create_variants/out", ], check=True, + env=os.environ ) # Check that metadata aligns with variant sim_data attrs with open("test_create_variants/out/metadata.json") as f: