Skip to content

Commit a73105f

Browse files
committed
fix tests
1 parent 71d5177 commit a73105f

2 files changed

Lines changed: 4 additions & 5 deletions

File tree

tests/test_grobid_client.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -258,7 +258,7 @@ def test_process_with_pdf_files(self, mock_walk):
258258
with patch('grobid_client.grobid_client.GrobidClient._test_server_connection'):
259259
with patch('grobid_client.grobid_client.GrobidClient._configure_logging'):
260260
with patch('grobid_client.grobid_client.GrobidClient.process_batch') as mock_batch:
261-
mock_batch.return_value = 2
261+
mock_batch.return_value = (2, 0) # Return tuple as expected
262262
client = GrobidClient(check_server=False)
263263
client.logger = Mock()
264264

@@ -421,7 +421,7 @@ def test_process_batch(self, mock_isfile, mock_executor):
421421
verbose=False
422422
)
423423

424-
assert result == 1 # One file processed
424+
assert result == (1, 0) # One file processed, zero errors
425425

426426

427427
class TestServerUnavailableException:

tests/test_integration.py

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -181,7 +181,7 @@ def test_batch_processing(self):
181181
force=True
182182
)
183183

184-
assert processed_count == 5
184+
assert processed_count == (5, 0)
185185

186186
def test_error_handling_and_recovery(self):
187187
"""Test error handling and recovery mechanisms."""
@@ -342,5 +342,4 @@ def test_concurrent_processing_stress(self):
342342
force=True
343343
)
344344

345-
assert processed_count == 20
346-
345+
assert processed_count == (20, 0)

0 commit comments

Comments
 (0)