fix(tests): fix failing integration tests, again

This commit is contained in:
perf3ct 2025-06-28 22:54:41 +00:00
parent 28a7e4eb45
commit 660117ed9f
No known key found for this signature in database
GPG Key ID: 569C4EEC436F5232
2 changed files with 4 additions and 2 deletions

View File

@ -144,7 +144,7 @@ impl FailedOcrTestClient {
/// Get failed OCR documents
async fn get_failed_ocr_documents(&self, limit: Option<i32>, offset: Option<i32>) -> Result<Value, Box<dyn std::error::Error + Send + Sync>> {
let mut url = format!("{}/api/documents/failed-ocr", get_base_url());
let mut url = format!("{}/api/documents/failed", get_base_url());
let mut params = Vec::new();
if let Some(l) = limit {
@ -153,6 +153,8 @@ impl FailedOcrTestClient {
if let Some(o) = offset {
params.push(format!("offset={}", o));
}
// Filter to only OCR failures since this is the OCR-specific test
params.push("stage=ocr".to_string());
if !params.is_empty() {
url.push_str(&format!("?{}", params.join("&")));

View File

@ -115,7 +115,7 @@ impl OcrFailureCountingTestClient {
/// Get failed OCR documents and statistics
async fn get_failed_ocr_documents(&self) -> Result<Value, Box<dyn std::error::Error + Send + Sync>> {
let response = self.client
.get(&format!("{}/api/documents/failed-ocr", get_base_url()))
.get(&format!("{}/api/documents/failed?stage=ocr", get_base_url()))
.header("Authorization", self.get_auth_header())
.timeout(TIMEOUT)
.send()