diff --git a/internal/mineru/live_test.go b/internal/mineru/live_test.go index 718c68fe..bff8a654 100644 --- a/internal/mineru/live_test.go +++ b/internal/mineru/live_test.go @@ -53,6 +53,12 @@ func TestLive_ParseTinyPDF(t *testing.T) { if pdfPath != "" && res.EngineMode == "" { t.Fatal("missing engine mode") } + // Dump a content sample so the report can prove real text was extracted. + if os.Getenv("MINERU_LIVE_DUMP") != "" { + _ = os.WriteFile(os.Getenv("MINERU_LIVE_DUMP"), []byte(res.Markdown), 0o644) + t.Logf("wrote %d bytes to %s; contains 冲击波=%v", + len(res.Markdown), os.Getenv("MINERU_LIVE_DUMP"), strings.Contains(res.Markdown, "冲击波")) + } } func getenv(k, def string) string {