Skip to content

Commit

Permalink
Create ProcSetTest.java
Browse files Browse the repository at this point in the history
  • Loading branch information
Wugengxian authored and asturio committed Apr 22, 2021
1 parent c5247f7 commit 88d7c2c
Showing 1 changed file with 26 additions and 0 deletions.
26 changes: 26 additions & 0 deletions openpdf/src/test/java/com/lowagie/text/pdf/table/ProcSetTest.java
Original file line number Diff line number Diff line change
@@ -0,0 +1,26 @@
package com.lowagie.text.pdf.table;

import com.lowagie.text.Chunk;
import com.lowagie.text.Document;
import com.lowagie.text.pdf.PdfName;
import com.lowagie.text.pdf.PdfReader;
import com.lowagie.text.pdf.PdfWriter;
import org.apache.commons.io.output.ByteArrayOutputStream;
import org.junit.jupiter.api.Assertions;
import org.junit.jupiter.api.Test;

import java.io.IOException;

public class ProcSetTest {
@Test
public void procSetTest1() throws IOException {
ByteArrayOutputStream stream = new ByteArrayOutputStream();
Document document = new Document();
PdfWriter.getInstance(document, stream);
document.open();
document.add(Chunk.NEWLINE);
document.close();
PdfReader reader = new PdfReader(stream.toByteArray());
Assertions.assertNull(reader.getPageN(1).getAsDict(PdfName.RESOURCES).get(PdfName.PROCSET));
}
}

0 comments on commit 88d7c2c

Please sign in to comment.