Skip to content

Commit 46f6cc7

Browse files
authored
Merge pull request #5 from microsoft-foundry/copilot/fix-github-actions-job
[WIP] Fix failing GitHub Actions job Test (Python 3.9 on windows-latest)
2 parents decfa5c + 62ae4f2 commit 46f6cc7

1 file changed

Lines changed: 9 additions & 2 deletions

File tree

tests/conftest.py

Lines changed: 9 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,10 +2,17 @@
22

33
from __future__ import annotations
44

5+
import sys
6+
from pathlib import Path
7+
58
import pytest
69

7-
from src.client import CompletionResult
8-
from src.config import EvalConfig, EndpointConfig, PricingConfig
10+
project_root = Path(__file__).resolve().parents[1]
11+
if str(project_root) not in sys.path:
12+
sys.path.insert(0, str(project_root))
13+
14+
from src.client import CompletionResult # noqa: E402
15+
from src.config import EvalConfig, EndpointConfig, PricingConfig # noqa: E402
916

1017

1118
@pytest.fixture

0 commit comments

Comments
 (0)