Skip to content

Commit

Permalink
chore: fix coverage
Browse files Browse the repository at this point in the history
  • Loading branch information
Goldziher committed Jan 10, 2025
1 parent 52c9890 commit 6dddcee
Show file tree
Hide file tree
Showing 2 changed files with 17 additions and 4 deletions.
8 changes: 4 additions & 4 deletions src/tika_client/client.py
Original file line number Diff line number Diff line change
Expand Up @@ -61,22 +61,22 @@ def __init__(

@property
@abstractmethod
def client(self) -> T:
def client(self) -> T: # pragma: no cover
pass

@property
@abstractmethod
def metadata(self) -> R:
def metadata(self) -> R: # pragma: no cover
pass

@property
@abstractmethod
def tika(self) -> R:
def tika(self) -> R: # pragma: no cover
pass

@property
@abstractmethod
def rmeta(self) -> R:
def rmeta(self) -> R: # pragma: no cover
pass


Expand Down
13 changes: 13 additions & 0 deletions tests/test_resource_tika.py
Original file line number Diff line number Diff line change
Expand Up @@ -294,6 +294,19 @@ async def test_parse_docx_from_buffer_as_html(
assert resp.content_length == 6183


class TestAsyncParseContentCompress:
async def test_parse_odt_from_bytes_buffer_compress(
self,
async_tika_client_compressed: AsyncTikaClient,
sample_office_doc_with_images_file: Path,
) -> None:
buffer = sample_office_doc_with_images_file.read_bytes()

resp = await async_tika_client_compressed.tika.as_text.from_buffer(buffer)

assert resp.type == "application/vnd.oasis.opendocument.text"


class TestAsyncParsePlain:
async def test_parse_docx_from_file_as_text(
self,
Expand Down

0 comments on commit 6dddcee

Please sign in to comment.