mirror of
https://github.com/OpenHands/OpenHands.git
synced 2025-12-26 05:48:36 +08:00
(fix) split_bash_commands replaced; temp_dir fixture fix in some tests (#3160)
* split_bash_commands replaced; temp_dir fixture fix in some tests * tweak test_runtime * skip 2 tests in test_runtime that need fixing in extra PR * reverting bash parsing changes and re-enabled tests * missed to revert a changed assert in test_runtime.py
This commit is contained in:
parent
7cefd32fd0
commit
2533efabbb
@ -16,7 +16,7 @@ from opendevin.storage import get_file_store
|
||||
def temp_dir(monkeypatch):
|
||||
# get a temporary directory
|
||||
with tempfile.TemporaryDirectory() as temp_dir:
|
||||
pathlib.Path().mkdir(parents=True, exist_ok=True)
|
||||
pathlib.Path(temp_dir).mkdir(parents=True, exist_ok=True)
|
||||
yield temp_dir
|
||||
|
||||
|
||||
|
||||
@ -14,7 +14,7 @@ from opendevin.runtime.server.runtime import ServerRuntime
|
||||
def temp_dir(monkeypatch):
|
||||
# get a temporary directory
|
||||
with tempfile.TemporaryDirectory() as temp_dir:
|
||||
pathlib.Path().mkdir(parents=True, exist_ok=True)
|
||||
pathlib.Path(temp_dir).mkdir(parents=True, exist_ok=True)
|
||||
yield temp_dir
|
||||
|
||||
|
||||
|
||||
@ -44,7 +44,7 @@ def print_method_name(request):
|
||||
def temp_dir(monkeypatch):
|
||||
# get a temporary directory
|
||||
with tempfile.TemporaryDirectory() as temp_dir:
|
||||
pathlib.Path().mkdir(parents=True, exist_ok=True)
|
||||
pathlib.Path(temp_dir).mkdir(parents=True, exist_ok=True)
|
||||
yield temp_dir
|
||||
|
||||
|
||||
|
||||
@ -32,11 +32,18 @@ def create_docker_box_from_app_config(
|
||||
)
|
||||
|
||||
|
||||
@pytest.fixture(autouse=True)
|
||||
def print_method_name(request):
|
||||
print('\n########################################################################')
|
||||
print(f'Running test: {request.node.name}')
|
||||
print('########################################################################')
|
||||
|
||||
|
||||
@pytest.fixture
|
||||
def temp_dir(monkeypatch):
|
||||
# get a temporary directory
|
||||
with tempfile.TemporaryDirectory() as temp_dir:
|
||||
pathlib.Path().mkdir(parents=True, exist_ok=True)
|
||||
pathlib.Path(temp_dir).mkdir(parents=True, exist_ok=True)
|
||||
yield temp_dir
|
||||
|
||||
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user