Package org.archive.modules.writer

Examples of org.archive.modules.writer.WARCWriterProcessor.report()


            assertTrue(curi1.getContentDigestHistory().isEmpty());

            warcWriter.process(curi1);
            assertEquals(curi1.getUURI().toString(), curi1.getContentDigestHistory().get(A_ORIGINAL_URL));
            assertEquals(1, curi1.getContentDigestHistory().get(A_CONTENT_DIGEST_COUNT));
            String report = warcWriter.report();
            assertTrue(report.contains("Total CrawlURIs:   1\n"));
            assertTrue(report.contains("Revisit records:   0\n"));

            storer().process(curi1);
            assertEquals(1, historyStore().store.size());
View Full Code Here


            warcWriter.process(curi2);
            assertTrue(curi2.getAnnotations().contains("duplicate:digest"));
            assertEquals(curi1.getUURI().toString(), curi2.getContentDigestHistory().get(A_ORIGINAL_URL));
            assertNotSame(curi2.getUURI().toString(), curi2.getContentDigestHistory().get(A_ORIGINAL_URL));
            assertEquals(2, curi2.getContentDigestHistory().get(A_CONTENT_DIGEST_COUNT));
            report = warcWriter.report();
            assertTrue(report.contains("Total CrawlURIs:   2\n"));
            assertTrue(report.contains("Revisit records:   1\n"));

            storer().process(curi2);
            assertEquals(1, historyStore().store.size());
View Full Code Here

TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.