Compare commits

...
Author SHA1 Message Date
MervinPraisonandClaude Opus 5.5 f37513d3b8 test: set the project root for headless YAML output_file tests
#5770 contains task output_file writes to the project root (cwd or
PRAISONAI_PROJECT_ROOT), matching Agent.output_file. These tests write under
tmp_path, which is outside the cwd, so main's test-core (root) failed with
'output_file not written'. Point the project root at tmp_path.

Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]>
2026-10-26 21:18:14 +00:00
@@ -52,6 +52,13 @@ class _MockOpenAI(BaseHTTPRequestHandler):
self.wfile.write(data)
@pytest.fixture(autouse=True)
def _project_root(tmp_path, monkeypatch):
# Task output_file writes are contained to the project root (#5770); these
# runs write under tmp_path, so make it the root.
monkeypatch.setenv("PRAISONAI_PROJECT_ROOT", str(tmp_path))
@pytest.fixture
def mock_endpoint(monkeypatch):
server = HTTPServer(("127.0.0.1", 0), _MockOpenAI)