cra-window-rules / tests /test_process_data.py
Mark Febrizio
Revisions 2024 06 (#11)
58bb4c7 unverified
raw
history blame
501 Bytes
#import pytest
from fr_toolbelt.api_requests import get_documents_by_date
from pandas import DataFrame
from modules.get_rules_in_window import (
format_documents,
)
START = "2024-03-01"
END = "2024-04-30"
#@pytest.fixture
def temp_documents():
return get_documents_by_date(START, end_date=END, document_types=("RULE", ))[0]
TEMP_DOCUMENTS = temp_documents()
def test_format_documents():
formatted = format_documents(TEMP_DOCUMENTS)
assert isinstance(formatted, DataFrame)