Skip to content

Commit eb02b40

Browse files
authored
added cwd change to test_config.py (#154)
1 parent 03da23e commit eb02b40

1 file changed

Lines changed: 11 additions & 0 deletions

File tree

test/test_config.py

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,7 @@
11
import copy
2+
import os
23
import unittest
4+
from pathlib import Path
35

46
import yaml
57
from seml import utils
@@ -12,6 +14,15 @@
1214

1315

1416
class TestParseConfigDicts(unittest.TestCase):
17+
@classmethod
18+
def setUpClass(cls):
19+
cls._orig_cwd = os.getcwd()
20+
os.chdir(Path(__file__).parent)
21+
22+
@classmethod
23+
def tearDownClass(cls):
24+
os.chdir(cls._orig_cwd)
25+
1526
SIMPLE_CONFIG_WITH_PARAMETER_COLLECTIONS = (
1627
"resources/config/config_with_parameter_collections.yaml"
1728
)

0 commit comments

Comments
 (0)