Skip to content

Commit 6b54d74

Browse files
committed
New fixture, vocablary raw text.
1 parent b8cc441 commit 6b54d74

File tree

1 file changed

+11
-0
lines changed

1 file changed

+11
-0
lines changed

tests/conftest.py

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,7 @@
11
"""PyTest Configurations."""
22

3+
from pathlib import Path
4+
35
import pytest
46

57
from llm.utils import create_vocab
@@ -9,3 +11,12 @@
911
def vocab() -> dict:
1012
"""Vocablary dict."""
1113
return create_vocab()
14+
15+
16+
@pytest.fixture()
17+
def vocab_text() -> str:
18+
"""Vocablary raw text."""
19+
file_path = Path.cwd() / "src/llm/resources/the-verdict.txt"
20+
with open(str(file_path), encoding="utf-8") as f:
21+
text = f.read()
22+
return text

0 commit comments

Comments
 (0)