import os
from pathlib import Path
import pytest
from cpex import PluginManager
FIXTURES_DIR = Path(__file__).parent / "fixtures"
PII_DENY_CONFIG = str(FIXTURES_DIR / "pii_deny.yaml")
PII_REDACT_CONFIG = str(FIXTURES_DIR / "pii_redact.yaml")
@pytest.fixture
async def manager():
mgr = PluginManager(PII_DENY_CONFIG)
await mgr.initialize()
yield mgr
await mgr.shutdown()
@pytest.fixture
def pii_deny_config_path() -> str:
return PII_DENY_CONFIG
@pytest.fixture
def pii_redact_config_path() -> str:
return PII_REDACT_CONFIG