示例#1
0
 public virtual void TestEventTypes()
 {
     String[] expectedTypes = new String[] { "pdfOcr-tesseract4-image-ocr", "pdfOcr-tesseract4-image-to-pdf", "pdfOcr-tesseract4-image-to-pdfa" };
     PdfOcrTesseract4Event[] testedEvents = new PdfOcrTesseract4Event[] { PdfOcrTesseract4Event.TESSERACT4_IMAGE_OCR
                                                                          , PdfOcrTesseract4Event.TESSERACT4_IMAGE_TO_PDF, PdfOcrTesseract4Event.TESSERACT4_IMAGE_TO_PDFA };
     for (int i = 0; i < testedEvents.Length; i++)
     {
         NUnit.Framework.Assert.AreEqual(expectedTypes[i], testedEvents[i].GetEventType());
     }
 }
示例#2
0
        public virtual void TestOriginId()
        {
            String expected = PDF_OCR_TESSERACT4_ORIGIN_ID;

            PdfOcrTesseract4Event[] testedEvents = new PdfOcrTesseract4Event[] { PdfOcrTesseract4Event.TESSERACT4_IMAGE_TO_PDF
                                                                                 , PdfOcrTesseract4Event.TESSERACT4_IMAGE_TO_PDF, PdfOcrTesseract4Event.TESSERACT4_IMAGE_TO_PDFA };
            foreach (PdfOcrTesseract4Event @event in testedEvents)
            {
                NUnit.Framework.Assert.AreEqual(expected, @event.GetOriginId());
            }
        }