[Git][java-team/libsejda-java][master] 4 commits: New upstream version 4.2.13
Markus Koschany (@apo)
gitlab at salsa.debian.org
Sat Feb 12 21:12:13 GMT 2022
Markus Koschany pushed to branch master at Debian Java Maintainers / libsejda-java
Commits:
cd46d6c4 by Markus Koschany at 2022-02-12T22:01:04+01:00
New upstream version 4.2.13
- - - - -
1b550a8b by Markus Koschany at 2022-02-12T22:01:38+01:00
Update upstream source from tag 'upstream/4.2.13'
Update to upstream version '4.2.13'
with Debian dir ee9db95c0581367e20ef85d98d8aaa8924e2ee3a
- - - - -
ac364e8a by Markus Koschany at 2022-02-12T22:02:24+01:00
Update changelog
- - - - -
020880f6 by Markus Koschany at 2022-02-12T22:05:40+01:00
Ignore com.tngtech.archunit:archunit-junit5:jar:debian
- - - - -
25 changed files:
- + .github/workflows/release.yml
- − .travis.settings.xml
- − .travis.yml
- debian/changelog
- debian/maven.ignoreRules
- + deps.txt
- pom.xml
- sejda-conversion/pom.xml
- − sejda-conversion/src/test/java/org/sejda/TestCyclesConversion.java
- + sejda-conversion/src/test/java/org/sejda/conversion/TestCycles.java
- sejda-core/pom.xml
- sejda-core/src/test/java/org/sejda/core/TestCyclesCore.java → sejda-core/src/test/java/org/sejda/core/TestCycles.java
- sejda-core/src/test/java/org/sejda/core/service/BaseTaskTest.java
- + sejda-core/src/test/resources/image/sample_heic.jpg
- sejda-distribution/pom.xml
- sejda-docs/pom.xml
- sejda-fonts/pom.xml
- sejda-image-writers/pom.xml
- sejda-model/pom.xml
- sejda-model/src/test/java/org/sejda/TestCycles.java
- sejda-sambox/pom.xml
- sejda-sambox/src/main/java/org/sejda/impl/sambox/component/PageImageWriter.java
- + sejda-sambox/src/test/java/org/sejda/impl/TestCycles.java
- − sejda-sambox/src/test/java/org/sejda/impl/TestCyclesSambox.java
- sejda-sambox/src/test/java/org/sejda/impl/sambox/component/PageImageWriterTest.java
Changes:
=====================================
.github/workflows/release.yml
=====================================
@@ -0,0 +1,35 @@
+name: release
+
+on:
+ push:
+ tags:
+ - '*'
+
+jobs:
+ build:
+ runs-on: ubuntu-latest
+ name: release
+
+ steps:
+ - name: Checkout repo
+ uses: actions/checkout at v2
+ - name: Import GPG key
+ id: import_gpg
+ uses: crazy-max/ghaction-import-gpg at v4
+ with:
+ gpg_private_key: ${{ secrets.OSSRH_GPG_SECRET_KEY }}
+ passphrase: ${{ secrets.OSSRH_GPG_SECRET_KEY_PASSWORD }}
+ - name: Set up JDK
+ uses: actions/setup-java at v2
+ with:
+ java-version: 8
+ distribution: 'temurin'
+ server-id: ossrh
+ server-username: OSSRH_USERNAME
+ server-password: OSSRH_TOKEN
+ cache: 'maven'
+ - name: Publish to Central
+ env:
+ OSSRH_USERNAME: ${{ secrets.OSSRH_USERNAME }}
+ OSSRH_TOKEN: ${{ secrets.OSSRH_TOKEN }}
+ run: mvn --no-transfer-progress --batch-mode -Prelease deploy
=====================================
.travis.settings.xml deleted
=====================================
@@ -1,9 +0,0 @@
-<settings xmlns="http://maven.apache.org/SETTINGS/1.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/SETTINGS/1.0.0 http://maven.apache.org/xsd/settings-1.0.0.xsd">
- <servers>
- <server>
- <id>ossrh</id>
- <username>${env.OSSRH_USER}</username>
- <password>${env.OSSRH_PWD}</password>
- </server>
- </servers>
-</settings>
\ No newline at end of file
=====================================
.travis.yml deleted
=====================================
@@ -1,35 +0,0 @@
-language: java
-sudo: false
-before_install:
-- openssl aes-256-cbc -K $encrypted_e19597da4fac_key -iv $encrypted_e19597da4fac_iv
- -in pgp.asc.enc -out pgp.asc -d
-- gpg --fast-import pgp.asc
-before_script: mvn javadoc:javadoc -DskipTests=true -B -V
-script: mvn clean install
-jdk:
-- openjdk8
-cache:
- directories:
- - "$HOME/.m2"
-env:
- global:
- #GPG_PASSPHRASE
- - secure: YqXA0mY5JW3EwtKQjWLMD7Q4dpHVoIpfgYjG2D1D2X67KfekN6h5NaQWCQsPV0AJvznbF/bWoNjUGscncukA2MW/Fz1kXmnnuFmsFQNQAYBCilO5L8/MPWd0UFmHNJQYq5NGw9ajduB46E8K3URMPzseZsZo6IPalJ9i1VKF/Cg=
-deploy:
-- provider: releases
- skip_cleanup: true
- file_glob: true
- api_key:
- secure: Ca89OLPkZ/qQ4/Ky2FBy7V0gFlhD8MGPWKLFI0FX/yCJn5I3ZmzSEIFBozym1HmG23zdofB2RfVn11c4EF1hjh2r3XUjucBV5L8xN0BLtA8s82OALBilfD+tmvUzhWUP7sG2enyeoAYFF+mNxkRFz4rx3Wn/tP1qeHDD54UNyUo=
- on:
- tags: true
- file:
- - sejda-distribution/target/*.zip
-- provider: script
- script: mvn deploy --settings .travis.settings.xml
- skip_cleanup: true
- on:
- tags: true
-notifications:
- email:
- - info at sejda.org
=====================================
debian/changelog
=====================================
@@ -1,3 +1,9 @@
+libsejda-java (4.2.13-1) unstable; urgency=medium
+
+ * New upstream version 4.2.13.
+
+ -- Markus Koschany <apo at debian.org> Sat, 12 Feb 2022 22:02:11 +0100
+
libsejda-java (4.2.11-1) unstable; urgency=medium
* New upstream version 4.2.11.
=====================================
debian/maven.ignoreRules
=====================================
@@ -20,3 +20,4 @@ org.mockito mockito-core * * * *
org.powermock powermock-module-junit4 * * * *
org.powermock powermock-api-mockito * * * *
org.codehaus.mojo appassembler-maven-plugin * * * *
+com.tngtech.archunit archunit-junit5 * * * *
=====================================
deps.txt
=====================================
@@ -0,0 +1,417 @@
+[INFO] Scanning for projects...
+[INFO] ------------------------------------------------------------------------
+[INFO] Reactor Build Order:
+[INFO]
+[INFO] sejda [pom]
+[INFO] sejda model [jar]
+[INFO] sejda core [jar]
+[INFO] Sejda docs [pom]
+[INFO] sejda fonts [jar]
+[INFO] sejda image writers [jar]
+[INFO] sejda sambox [jar]
+[INFO] sejda conversion [jar]
+[INFO] sejda distribution [pom]
+[INFO]
+[INFO] -----------------------< org.sejda:sejda-parent >-----------------------
+[INFO] Building sejda 4.2.12-SNAPSHOT [1/9]
+[INFO] --------------------------------[ pom ]---------------------------------
+[INFO]
+[INFO] --- maven-dependency-plugin:2.8:tree (default-cli) @ sejda-parent ---
+[INFO] org.sejda:sejda-parent:pom:4.2.12-SNAPSHOT
+[INFO] +- org.sejda:sejda-commons:jar:1.1.7:compile
+[INFO] +- org.slf4j:slf4j-api:jar:1.7.32:compile
+[INFO] +- org.mockito:mockito-core:jar:4.1.0:test
+[INFO] | +- net.bytebuddy:byte-buddy:jar:1.12.1:test
+[INFO] | +- net.bytebuddy:byte-buddy-agent:jar:1.12.1:test
+[INFO] | \- org.objenesis:objenesis:jar:3.2:test
+[INFO] +- org.sejda:sambox:jar:2.3.4:test
+[INFO] | +- org.slf4j:jcl-over-slf4j:jar:1.7.30:test
+[INFO] | +- org.sejda:sejda-io:jar:2.1.1:test
+[INFO] | \- org.apache.pdfbox:fontbox:jar:2.0.18:test
+[INFO] +- ch.qos.logback:logback-classic:jar:1.2.9:test
+[INFO] | \- ch.qos.logback:logback-core:jar:1.2.9:test
+[INFO] +- org.junit.jupiter:junit-jupiter-engine:jar:5.8.2:test
+[INFO] | +- org.junit.platform:junit-platform-engine:jar:1.8.2:test
+[INFO] | | +- org.opentest4j:opentest4j:jar:1.2.0:test
+[INFO] | | \- org.junit.platform:junit-platform-commons:jar:1.8.2:test
+[INFO] | +- org.junit.jupiter:junit-jupiter-api:jar:5.8.2:test
+[INFO] | \- org.apiguardian:apiguardian-api:jar:1.1.2:test
+[INFO] +- org.junit.vintage:junit-vintage-engine:jar:5.8.2:test
+[INFO] | \- junit:junit:jar:4.13.2:test
+[INFO] +- org.hamcrest:hamcrest-core:jar:2.2:test
+[INFO] | \- org.hamcrest:hamcrest:jar:2.2:test
+[INFO] \- com.tngtech.archunit:archunit-junit5:jar:0.22.0:test
+[INFO] +- com.tngtech.archunit:archunit-junit5-api:jar:0.22.0:test
+[INFO] | \- com.tngtech.archunit:archunit:jar:0.22.0:test
+[INFO] \- com.tngtech.archunit:archunit-junit5-engine:jar:0.22.0:test
+[INFO] \- com.tngtech.archunit:archunit-junit5-engine-api:jar:0.22.0:test
+[INFO]
+[INFO] -----------------------< org.sejda:sejda-model >------------------------
+[INFO] Building sejda model 4.2.12-SNAPSHOT [2/9]
+[INFO] --------------------------------[ jar ]---------------------------------
+[INFO]
+[INFO] --- maven-dependency-plugin:2.8:tree (default-cli) @ sejda-model ---
+[INFO] org.sejda:sejda-model:jar:4.2.12-SNAPSHOT
+[INFO] +- org.apache.commons:commons-lang3:jar:3.12.0:compile
+[INFO] +- commons-io:commons-io:jar:2.11.0:compile
+[INFO] +- org.sejda:sejda-io:jar:2.1.3:compile
+[INFO] +- javax.validation:validation-api:jar:1.0.0.GA:compile
+[INFO] +- org.hibernate:hibernate-validator:jar:4.2.0.Final:test
+[INFO] +- org.sejda:sejda-commons:jar:1.1.7:compile
+[INFO] +- org.slf4j:slf4j-api:jar:1.7.32:compile
+[INFO] +- org.mockito:mockito-core:jar:4.1.0:test
+[INFO] | +- net.bytebuddy:byte-buddy:jar:1.12.1:test
+[INFO] | +- net.bytebuddy:byte-buddy-agent:jar:1.12.1:test
+[INFO] | \- org.objenesis:objenesis:jar:3.2:test
+[INFO] +- org.sejda:sambox:jar:2.3.4:test
+[INFO] | +- org.slf4j:jcl-over-slf4j:jar:1.7.30:test
+[INFO] | \- org.apache.pdfbox:fontbox:jar:2.0.18:test
+[INFO] +- ch.qos.logback:logback-classic:jar:1.2.9:test
+[INFO] | \- ch.qos.logback:logback-core:jar:1.2.9:test
+[INFO] +- org.junit.jupiter:junit-jupiter-engine:jar:5.8.2:test
+[INFO] | +- org.junit.platform:junit-platform-engine:jar:1.8.2:test
+[INFO] | | +- org.opentest4j:opentest4j:jar:1.2.0:test
+[INFO] | | \- org.junit.platform:junit-platform-commons:jar:1.8.2:test
+[INFO] | +- org.junit.jupiter:junit-jupiter-api:jar:5.8.2:test
+[INFO] | \- org.apiguardian:apiguardian-api:jar:1.1.2:test
+[INFO] +- org.junit.vintage:junit-vintage-engine:jar:5.8.2:test
+[INFO] | \- junit:junit:jar:4.13.2:test
+[INFO] +- org.hamcrest:hamcrest-core:jar:2.2:test
+[INFO] | \- org.hamcrest:hamcrest:jar:2.2:test
+[INFO] \- com.tngtech.archunit:archunit-junit5:jar:0.22.0:test
+[INFO] +- com.tngtech.archunit:archunit-junit5-api:jar:0.22.0:test
+[INFO] | \- com.tngtech.archunit:archunit:jar:0.22.0:test
+[INFO] \- com.tngtech.archunit:archunit-junit5-engine:jar:0.22.0:test
+[INFO] \- com.tngtech.archunit:archunit-junit5-engine-api:jar:0.22.0:test
+[INFO]
+[INFO] ------------------------< org.sejda:sejda-core >------------------------
+[INFO] Building sejda core 4.2.12-SNAPSHOT [3/9]
+[INFO] --------------------------------[ jar ]---------------------------------
+[INFO]
+[INFO] --- maven-dependency-plugin:2.8:tree (default-cli) @ sejda-core ---
+[INFO] org.sejda:sejda-core:jar:4.2.12-SNAPSHOT
+[INFO] +- org.sejda:sejda-model:jar:4.2.12-SNAPSHOT:compile
+[INFO] | \- org.sejda:sejda-io:jar:2.1.3:compile
+[INFO] +- org.apache.commons:commons-lang3:jar:3.12.0:compile
+[INFO] +- commons-io:commons-io:jar:2.11.0:compile
+[INFO] +- javax.validation:validation-api:jar:1.0.0.GA:compile
+[INFO] +- org.hibernate:hibernate-validator:jar:4.2.0.Final:compile
+[INFO] +- org.sejda:sejda-model:test-jar:tests:4.2.12-SNAPSHOT:test
+[INFO] +- org.sejda:sejda-commons:jar:1.1.7:compile
+[INFO] +- org.slf4j:slf4j-api:jar:1.7.32:compile
+[INFO] +- org.mockito:mockito-core:jar:4.1.0:test
+[INFO] | +- net.bytebuddy:byte-buddy:jar:1.12.1:test
+[INFO] | +- net.bytebuddy:byte-buddy-agent:jar:1.12.1:test
+[INFO] | \- org.objenesis:objenesis:jar:3.2:test
+[INFO] +- org.sejda:sambox:jar:2.3.4:test
+[INFO] | +- org.slf4j:jcl-over-slf4j:jar:1.7.30:test
+[INFO] | \- org.apache.pdfbox:fontbox:jar:2.0.18:test
+[INFO] +- ch.qos.logback:logback-classic:jar:1.2.9:test
+[INFO] | \- ch.qos.logback:logback-core:jar:1.2.9:test
+[INFO] +- org.junit.jupiter:junit-jupiter-engine:jar:5.8.2:test
+[INFO] | +- org.junit.platform:junit-platform-engine:jar:1.8.2:test
+[INFO] | | +- org.opentest4j:opentest4j:jar:1.2.0:test
+[INFO] | | \- org.junit.platform:junit-platform-commons:jar:1.8.2:test
+[INFO] | +- org.junit.jupiter:junit-jupiter-api:jar:5.8.2:test
+[INFO] | \- org.apiguardian:apiguardian-api:jar:1.1.2:test
+[INFO] +- org.junit.vintage:junit-vintage-engine:jar:5.8.2:test
+[INFO] | \- junit:junit:jar:4.13.2:test
+[INFO] +- org.hamcrest:hamcrest-core:jar:2.2:test
+[INFO] | \- org.hamcrest:hamcrest:jar:2.2:test
+[INFO] \- com.tngtech.archunit:archunit-junit5:jar:0.22.0:test
+[INFO] +- com.tngtech.archunit:archunit-junit5-api:jar:0.22.0:test
+[INFO] | \- com.tngtech.archunit:archunit:jar:0.22.0:test
+[INFO] \- com.tngtech.archunit:archunit-junit5-engine:jar:0.22.0:test
+[INFO] \- com.tngtech.archunit:archunit-junit5-engine-api:jar:0.22.0:test
+[INFO]
+[INFO] ------------------------< org.sejda:sejda-docs >------------------------
+[INFO] Building Sejda docs 4.2.12-SNAPSHOT [4/9]
+[INFO] --------------------------------[ pom ]---------------------------------
+[INFO]
+[INFO] --- maven-dependency-plugin:2.8:tree (default-cli) @ sejda-docs ---
+[INFO] org.sejda:sejda-docs:pom:4.2.12-SNAPSHOT
+[INFO] +- org.sejda:sejda-commons:jar:1.1.7:compile
+[INFO] +- org.slf4j:slf4j-api:jar:1.7.32:compile
+[INFO] +- org.mockito:mockito-core:jar:4.1.0:test
+[INFO] | +- net.bytebuddy:byte-buddy:jar:1.12.1:test
+[INFO] | +- net.bytebuddy:byte-buddy-agent:jar:1.12.1:test
+[INFO] | \- org.objenesis:objenesis:jar:3.2:test
+[INFO] +- org.sejda:sambox:jar:2.3.4:test
+[INFO] | +- org.slf4j:jcl-over-slf4j:jar:1.7.30:test
+[INFO] | +- org.sejda:sejda-io:jar:2.1.1:test
+[INFO] | \- org.apache.pdfbox:fontbox:jar:2.0.18:test
+[INFO] +- ch.qos.logback:logback-classic:jar:1.2.9:test
+[INFO] | \- ch.qos.logback:logback-core:jar:1.2.9:test
+[INFO] +- org.junit.jupiter:junit-jupiter-engine:jar:5.8.2:test
+[INFO] | +- org.junit.platform:junit-platform-engine:jar:1.8.2:test
+[INFO] | | +- org.opentest4j:opentest4j:jar:1.2.0:test
+[INFO] | | \- org.junit.platform:junit-platform-commons:jar:1.8.2:test
+[INFO] | +- org.junit.jupiter:junit-jupiter-api:jar:5.8.2:test
+[INFO] | \- org.apiguardian:apiguardian-api:jar:1.1.2:test
+[INFO] +- org.junit.vintage:junit-vintage-engine:jar:5.8.2:test
+[INFO] | \- junit:junit:jar:4.13.2:test
+[INFO] +- org.hamcrest:hamcrest-core:jar:2.2:test
+[INFO] | \- org.hamcrest:hamcrest:jar:2.2:test
+[INFO] \- com.tngtech.archunit:archunit-junit5:jar:0.22.0:test
+[INFO] +- com.tngtech.archunit:archunit-junit5-api:jar:0.22.0:test
+[INFO] | \- com.tngtech.archunit:archunit:jar:0.22.0:test
+[INFO] \- com.tngtech.archunit:archunit-junit5-engine:jar:0.22.0:test
+[INFO] \- com.tngtech.archunit:archunit-junit5-engine-api:jar:0.22.0:test
+[INFO]
+[INFO] -----------------------< org.sejda:sejda-fonts >------------------------
+[INFO] Building sejda fonts 4.2.12-SNAPSHOT [5/9]
+[INFO] --------------------------------[ jar ]---------------------------------
+[INFO]
+[INFO] --- maven-dependency-plugin:2.8:tree (default-cli) @ sejda-fonts ---
+[INFO] org.sejda:sejda-fonts:jar:4.2.12-SNAPSHOT
+[INFO] +- org.sejda:sejda-model:jar:4.2.12-SNAPSHOT:compile
+[INFO] | +- org.apache.commons:commons-lang3:jar:3.12.0:compile
+[INFO] | +- commons-io:commons-io:jar:2.11.0:compile
+[INFO] | +- org.sejda:sejda-io:jar:2.1.3:compile
+[INFO] | \- javax.validation:validation-api:jar:1.0.0.GA:compile
+[INFO] +- org.sejda:sejda-model:test-jar:tests:4.2.12-SNAPSHOT:test
+[INFO] +- org.sejda:sejda-commons:jar:1.1.7:compile
+[INFO] +- org.slf4j:slf4j-api:jar:1.7.32:compile
+[INFO] +- org.mockito:mockito-core:jar:4.1.0:test
+[INFO] | +- net.bytebuddy:byte-buddy:jar:1.12.1:test
+[INFO] | +- net.bytebuddy:byte-buddy-agent:jar:1.12.1:test
+[INFO] | \- org.objenesis:objenesis:jar:3.2:test
+[INFO] +- org.sejda:sambox:jar:2.3.4:test
+[INFO] | +- org.slf4j:jcl-over-slf4j:jar:1.7.30:test
+[INFO] | \- org.apache.pdfbox:fontbox:jar:2.0.18:test
+[INFO] +- ch.qos.logback:logback-classic:jar:1.2.9:test
+[INFO] | \- ch.qos.logback:logback-core:jar:1.2.9:test
+[INFO] +- org.junit.jupiter:junit-jupiter-engine:jar:5.8.2:test
+[INFO] | +- org.junit.platform:junit-platform-engine:jar:1.8.2:test
+[INFO] | | +- org.opentest4j:opentest4j:jar:1.2.0:test
+[INFO] | | \- org.junit.platform:junit-platform-commons:jar:1.8.2:test
+[INFO] | +- org.junit.jupiter:junit-jupiter-api:jar:5.8.2:test
+[INFO] | \- org.apiguardian:apiguardian-api:jar:1.1.2:test
+[INFO] +- org.junit.vintage:junit-vintage-engine:jar:5.8.2:test
+[INFO] | \- junit:junit:jar:4.13.2:test
+[INFO] +- org.hamcrest:hamcrest-core:jar:2.2:test
+[INFO] | \- org.hamcrest:hamcrest:jar:2.2:test
+[INFO] \- com.tngtech.archunit:archunit-junit5:jar:0.22.0:test
+[INFO] +- com.tngtech.archunit:archunit-junit5-api:jar:0.22.0:test
+[INFO] | \- com.tngtech.archunit:archunit:jar:0.22.0:test
+[INFO] \- com.tngtech.archunit:archunit-junit5-engine:jar:0.22.0:test
+[INFO] \- com.tngtech.archunit:archunit-junit5-engine-api:jar:0.22.0:test
+[INFO]
+[INFO] -------------------< org.sejda:sejda-image-writers >--------------------
+[INFO] Building sejda image writers 4.2.12-SNAPSHOT [6/9]
+[INFO] --------------------------------[ jar ]---------------------------------
+[INFO]
+[INFO] --- maven-dependency-plugin:2.8:tree (default-cli) @ sejda-image-writers ---
+[INFO] org.sejda:sejda-image-writers:jar:4.2.12-SNAPSHOT
+[INFO] +- org.sejda:sejda-model:test-jar:tests:4.2.12-SNAPSHOT:test
+[INFO] | +- commons-io:commons-io:jar:2.11.0:compile
+[INFO] | +- org.sejda:sejda-io:jar:2.1.3:compile
+[INFO] | \- javax.validation:validation-api:jar:1.0.0.GA:compile
+[INFO] +- org.sejda:sejda-model:jar:4.2.12-SNAPSHOT:compile
+[INFO] +- com.twelvemonkeys.imageio:imageio-core:jar:3.8.0:compile
+[INFO] | +- com.twelvemonkeys.common:common-lang:jar:3.8.0:compile
+[INFO] | +- com.twelvemonkeys.common:common-io:jar:3.8.0:compile
+[INFO] | \- com.twelvemonkeys.common:common-image:jar:3.8.0:compile
+[INFO] +- com.twelvemonkeys.imageio:imageio-metadata:jar:3.8.0:compile
+[INFO] +- com.twelvemonkeys.imageio:imageio-tiff:jar:3.8.0:compile
+[INFO] +- com.twelvemonkeys.imageio:imageio-jpeg:jar:3.8.0:compile
+[INFO] +- org.apache.commons:commons-lang3:jar:3.12.0:compile
+[INFO] +- org.sejda:sejda-commons:jar:1.1.7:compile
+[INFO] +- org.slf4j:slf4j-api:jar:1.7.32:compile
+[INFO] +- org.mockito:mockito-core:jar:4.1.0:test
+[INFO] | +- net.bytebuddy:byte-buddy:jar:1.12.1:test
+[INFO] | +- net.bytebuddy:byte-buddy-agent:jar:1.12.1:test
+[INFO] | \- org.objenesis:objenesis:jar:3.2:test
+[INFO] +- org.sejda:sambox:jar:2.3.4:test
+[INFO] | +- org.slf4j:jcl-over-slf4j:jar:1.7.30:test
+[INFO] | \- org.apache.pdfbox:fontbox:jar:2.0.18:test
+[INFO] +- ch.qos.logback:logback-classic:jar:1.2.9:test
+[INFO] | \- ch.qos.logback:logback-core:jar:1.2.9:test
+[INFO] +- org.junit.jupiter:junit-jupiter-engine:jar:5.8.2:test
+[INFO] | +- org.junit.platform:junit-platform-engine:jar:1.8.2:test
+[INFO] | | +- org.opentest4j:opentest4j:jar:1.2.0:test
+[INFO] | | \- org.junit.platform:junit-platform-commons:jar:1.8.2:test
+[INFO] | +- org.junit.jupiter:junit-jupiter-api:jar:5.8.2:test
+[INFO] | \- org.apiguardian:apiguardian-api:jar:1.1.2:test
+[INFO] +- org.junit.vintage:junit-vintage-engine:jar:5.8.2:test
+[INFO] | \- junit:junit:jar:4.13.2:test
+[INFO] +- org.hamcrest:hamcrest-core:jar:2.2:test
+[INFO] | \- org.hamcrest:hamcrest:jar:2.2:test
+[INFO] \- com.tngtech.archunit:archunit-junit5:jar:0.22.0:test
+[INFO] +- com.tngtech.archunit:archunit-junit5-api:jar:0.22.0:test
+[INFO] | \- com.tngtech.archunit:archunit:jar:0.22.0:test
+[INFO] \- com.tngtech.archunit:archunit-junit5-engine:jar:0.22.0:test
+[INFO] \- com.tngtech.archunit:archunit-junit5-engine-api:jar:0.22.0:test
+[INFO]
+[INFO] -----------------------< org.sejda:sejda-sambox >-----------------------
+[INFO] Building sejda sambox 4.2.12-SNAPSHOT [7/9]
+[INFO] --------------------------------[ jar ]---------------------------------
+[INFO]
+[INFO] --- maven-dependency-plugin:2.8:tree (default-cli) @ sejda-sambox ---
+[INFO] org.sejda:sejda-sambox:jar:4.2.12-SNAPSHOT
+[INFO] +- org.sejda:sejda-core:test-jar:tests:4.2.12-SNAPSHOT:test
+[INFO] | +- javax.validation:validation-api:jar:1.0.0.GA:compile
+[INFO] | \- org.hibernate:hibernate-validator:jar:4.2.0.Final:compile
+[INFO] +- org.sejda:sejda-model:test-jar:tests:4.2.12-SNAPSHOT:test
+[INFO] | \- org.sejda:sejda-io:jar:2.1.3:compile
+[INFO] +- org.sejda:sejda-core:jar:4.2.12-SNAPSHOT:compile
+[INFO] +- org.sejda:sejda-model:jar:4.2.12-SNAPSHOT:compile
+[INFO] +- org.sejda:sejda-fonts:jar:4.2.12-SNAPSHOT:compile
+[INFO] +- org.sejda:sambox:jar:2.3.4:compile
+[INFO] | \- org.apache.pdfbox:fontbox:jar:2.0.18:compile
+[INFO] +- org.sejda:sejda-image-writers:jar:4.2.12-SNAPSHOT:compile
+[INFO] | +- com.twelvemonkeys.imageio:imageio-core:jar:3.8.0:compile
+[INFO] | | +- com.twelvemonkeys.common:common-lang:jar:3.8.0:compile
+[INFO] | | +- com.twelvemonkeys.common:common-io:jar:3.8.0:compile
+[INFO] | | \- com.twelvemonkeys.common:common-image:jar:3.8.0:compile
+[INFO] | +- com.twelvemonkeys.imageio:imageio-metadata:jar:3.8.0:compile
+[INFO] | +- com.twelvemonkeys.imageio:imageio-tiff:jar:3.8.0:compile
+[INFO] | \- com.twelvemonkeys.imageio:imageio-jpeg:jar:3.8.0:compile
+[INFO] +- org.bouncycastle:bcmail-jdk15on:jar:1.70:compile
+[INFO] | +- org.bouncycastle:bcutil-jdk15on:jar:1.70:compile
+[INFO] | \- org.bouncycastle:bcpkix-jdk15on:jar:1.70:compile
+[INFO] +- org.bouncycastle:bcprov-jdk15on:jar:1.70:compile
+[INFO] +- com.drewnoakes:metadata-extractor:jar:2.16.0:compile
+[INFO] | \- com.adobe.xmp:xmpcore:jar:6.1.11:compile
+[INFO] +- org.apache.commons:commons-lang3:jar:3.12.0:compile
+[INFO] +- commons-io:commons-io:jar:2.11.0:compile
+[INFO] +- net.coobird:thumbnailator:jar:0.4.15:compile
+[INFO] +- org.slf4j:jcl-over-slf4j:jar:1.7.32:test
+[INFO] +- org.sejda:sejda-commons:jar:1.1.7:compile
+[INFO] +- org.slf4j:slf4j-api:jar:1.7.32:compile
+[INFO] +- org.mockito:mockito-core:jar:4.1.0:test
+[INFO] | +- net.bytebuddy:byte-buddy:jar:1.12.1:test
+[INFO] | +- net.bytebuddy:byte-buddy-agent:jar:1.12.1:test
+[INFO] | \- org.objenesis:objenesis:jar:3.2:test
+[INFO] +- ch.qos.logback:logback-classic:jar:1.2.9:test
+[INFO] | \- ch.qos.logback:logback-core:jar:1.2.9:test
+[INFO] +- org.junit.jupiter:junit-jupiter-engine:jar:5.8.2:test
+[INFO] | +- org.junit.platform:junit-platform-engine:jar:1.8.2:test
+[INFO] | | +- org.opentest4j:opentest4j:jar:1.2.0:test
+[INFO] | | \- org.junit.platform:junit-platform-commons:jar:1.8.2:test
+[INFO] | +- org.junit.jupiter:junit-jupiter-api:jar:5.8.2:test
+[INFO] | \- org.apiguardian:apiguardian-api:jar:1.1.2:test
+[INFO] +- org.junit.vintage:junit-vintage-engine:jar:5.8.2:test
+[INFO] | \- junit:junit:jar:4.13.2:test
+[INFO] +- org.hamcrest:hamcrest-core:jar:2.2:test
+[INFO] | \- org.hamcrest:hamcrest:jar:2.2:test
+[INFO] \- com.tngtech.archunit:archunit-junit5:jar:0.22.0:test
+[INFO] +- com.tngtech.archunit:archunit-junit5-api:jar:0.22.0:test
+[INFO] | \- com.tngtech.archunit:archunit:jar:0.22.0:test
+[INFO] \- com.tngtech.archunit:archunit-junit5-engine:jar:0.22.0:test
+[INFO] \- com.tngtech.archunit:archunit-junit5-engine-api:jar:0.22.0:test
+[INFO]
+[INFO] ---------------------< org.sejda:sejda-conversion >---------------------
+[INFO] Building sejda conversion 4.2.12-SNAPSHOT [8/9]
+[INFO] --------------------------------[ jar ]---------------------------------
+[INFO]
+[INFO] --- maven-dependency-plugin:2.8:tree (default-cli) @ sejda-conversion ---
+[INFO] org.sejda:sejda-conversion:jar:4.2.12-SNAPSHOT
+[INFO] +- org.sejda:sejda-model:jar:4.2.12-SNAPSHOT:compile
+[INFO] | +- org.apache.commons:commons-lang3:jar:3.12.0:compile
+[INFO] | +- commons-io:commons-io:jar:2.11.0:compile
+[INFO] | +- org.sejda:sejda-io:jar:2.1.3:compile
+[INFO] | \- javax.validation:validation-api:jar:1.0.0.GA:compile
+[INFO] +- org.sejda:sejda-model:test-jar:tests:4.2.12-SNAPSHOT:test
+[INFO] +- org.sejda:sejda-commons:jar:1.1.7:compile
+[INFO] +- org.slf4j:slf4j-api:jar:1.7.32:compile
+[INFO] +- org.mockito:mockito-core:jar:4.1.0:test
+[INFO] | +- net.bytebuddy:byte-buddy:jar:1.12.1:test
+[INFO] | +- net.bytebuddy:byte-buddy-agent:jar:1.12.1:test
+[INFO] | \- org.objenesis:objenesis:jar:3.2:test
+[INFO] +- org.sejda:sambox:jar:2.3.4:test
+[INFO] | +- org.slf4j:jcl-over-slf4j:jar:1.7.30:test
+[INFO] | \- org.apache.pdfbox:fontbox:jar:2.0.18:test
+[INFO] +- ch.qos.logback:logback-classic:jar:1.2.9:test
+[INFO] | \- ch.qos.logback:logback-core:jar:1.2.9:test
+[INFO] +- org.junit.jupiter:junit-jupiter-engine:jar:5.8.2:test
+[INFO] | +- org.junit.platform:junit-platform-engine:jar:1.8.2:test
+[INFO] | | +- org.opentest4j:opentest4j:jar:1.2.0:test
+[INFO] | | \- org.junit.platform:junit-platform-commons:jar:1.8.2:test
+[INFO] | +- org.junit.jupiter:junit-jupiter-api:jar:5.8.2:test
+[INFO] | \- org.apiguardian:apiguardian-api:jar:1.1.2:test
+[INFO] +- org.junit.vintage:junit-vintage-engine:jar:5.8.2:test
+[INFO] | \- junit:junit:jar:4.13.2:test
+[INFO] +- org.hamcrest:hamcrest-core:jar:2.2:test
+[INFO] | \- org.hamcrest:hamcrest:jar:2.2:test
+[INFO] \- com.tngtech.archunit:archunit-junit5:jar:0.22.0:test
+[INFO] +- com.tngtech.archunit:archunit-junit5-api:jar:0.22.0:test
+[INFO] | \- com.tngtech.archunit:archunit:jar:0.22.0:test
+[INFO] \- com.tngtech.archunit:archunit-junit5-engine:jar:0.22.0:test
+[INFO] \- com.tngtech.archunit:archunit-junit5-engine-api:jar:0.22.0:test
+[INFO]
+[INFO] --------------------< org.sejda:sejda-distribution >--------------------
+[INFO] Building sejda distribution 4.2.12-SNAPSHOT [9/9]
+[INFO] --------------------------------[ pom ]---------------------------------
+[INFO]
+[INFO] --- maven-dependency-plugin:2.8:tree (default-cli) @ sejda-distribution ---
+[INFO] org.sejda:sejda-distribution:pom:4.2.12-SNAPSHOT
+[INFO] +- org.sejda:sejda-core:jar:4.2.12-SNAPSHOT:compile
+[INFO] | +- org.apache.commons:commons-lang3:jar:3.12.0:compile
+[INFO] | +- commons-io:commons-io:jar:2.11.0:compile
+[INFO] | +- javax.validation:validation-api:jar:1.0.0.GA:compile
+[INFO] | \- org.hibernate:hibernate-validator:jar:4.2.0.Final:compile
+[INFO] +- org.sejda:sejda-sambox:jar:4.2.12-SNAPSHOT:compile
+[INFO] | +- org.bouncycastle:bcmail-jdk15on:jar:1.70:compile
+[INFO] | | +- org.bouncycastle:bcutil-jdk15on:jar:1.70:compile
+[INFO] | | \- org.bouncycastle:bcpkix-jdk15on:jar:1.70:compile
+[INFO] | +- org.bouncycastle:bcprov-jdk15on:jar:1.70:compile
+[INFO] | +- com.drewnoakes:metadata-extractor:jar:2.16.0:compile
+[INFO] | | \- com.adobe.xmp:xmpcore:jar:6.1.11:compile
+[INFO] | \- net.coobird:thumbnailator:jar:0.4.15:compile
+[INFO] +- org.sejda:sejda-image-writers:jar:4.2.12-SNAPSHOT:compile
+[INFO] | +- com.twelvemonkeys.imageio:imageio-core:jar:3.8.0:compile
+[INFO] | | +- com.twelvemonkeys.common:common-lang:jar:3.8.0:compile
+[INFO] | | +- com.twelvemonkeys.common:common-io:jar:3.8.0:compile
+[INFO] | | \- com.twelvemonkeys.common:common-image:jar:3.8.0:compile
+[INFO] | +- com.twelvemonkeys.imageio:imageio-metadata:jar:3.8.0:compile
+[INFO] | +- com.twelvemonkeys.imageio:imageio-tiff:jar:3.8.0:compile
+[INFO] | \- com.twelvemonkeys.imageio:imageio-jpeg:jar:3.8.0:compile
+[INFO] +- org.sejda:sejda-conversion:jar:4.2.12-SNAPSHOT:compile
+[INFO] +- org.sejda:sejda-model:jar:4.2.12-SNAPSHOT:compile
+[INFO] | \- org.sejda:sejda-io:jar:2.1.3:compile
+[INFO] +- org.sejda:sejda-fonts:jar:4.2.12-SNAPSHOT:compile
+[INFO] +- org.sejda:sejda-commons:jar:1.1.7:compile
+[INFO] +- org.slf4j:slf4j-api:jar:1.7.32:compile
+[INFO] +- org.mockito:mockito-core:jar:4.1.0:test
+[INFO] | +- net.bytebuddy:byte-buddy:jar:1.12.1:test
+[INFO] | +- net.bytebuddy:byte-buddy-agent:jar:1.12.1:test
+[INFO] | \- org.objenesis:objenesis:jar:3.2:test
+[INFO] +- org.sejda:sambox:jar:2.3.4:test
+[INFO] | +- org.slf4j:jcl-over-slf4j:jar:1.7.30:test
+[INFO] | \- org.apache.pdfbox:fontbox:jar:2.0.18:test
+[INFO] +- ch.qos.logback:logback-classic:jar:1.2.9:test
+[INFO] | \- ch.qos.logback:logback-core:jar:1.2.9:test
+[INFO] +- org.junit.jupiter:junit-jupiter-engine:jar:5.8.2:test
+[INFO] | +- org.junit.platform:junit-platform-engine:jar:1.8.2:test
+[INFO] | | +- org.opentest4j:opentest4j:jar:1.2.0:test
+[INFO] | | \- org.junit.platform:junit-platform-commons:jar:1.8.2:test
+[INFO] | +- org.junit.jupiter:junit-jupiter-api:jar:5.8.2:test
+[INFO] | \- org.apiguardian:apiguardian-api:jar:1.1.2:test
+[INFO] +- org.junit.vintage:junit-vintage-engine:jar:5.8.2:test
+[INFO] | \- junit:junit:jar:4.13.2:test
+[INFO] +- org.hamcrest:hamcrest-core:jar:2.2:test
+[INFO] | \- org.hamcrest:hamcrest:jar:2.2:test
+[INFO] \- com.tngtech.archunit:archunit-junit5:jar:0.22.0:test
+[INFO] +- com.tngtech.archunit:archunit-junit5-api:jar:0.22.0:test
+[INFO] | \- com.tngtech.archunit:archunit:jar:0.22.0:test
+[INFO] \- com.tngtech.archunit:archunit-junit5-engine:jar:0.22.0:test
+[INFO] \- com.tngtech.archunit:archunit-junit5-engine-api:jar:0.22.0:test
+[INFO] ------------------------------------------------------------------------
+[INFO] Reactor Summary for sejda 4.2.12-SNAPSHOT:
+[INFO]
+[INFO] sejda .............................................. SUCCESS [ 0.394 s]
+[INFO] sejda model ........................................ SUCCESS [ 0.043 s]
+[INFO] sejda core ......................................... SUCCESS [ 0.024 s]
+[INFO] Sejda docs ......................................... SUCCESS [ 0.014 s]
+[INFO] sejda fonts ........................................ SUCCESS [ 0.017 s]
+[INFO] sejda image writers ................................ SUCCESS [ 0.029 s]
+[INFO] sejda sambox ....................................... SUCCESS [ 0.032 s]
+[INFO] sejda conversion ................................... SUCCESS [ 0.016 s]
+[INFO] sejda distribution ................................. SUCCESS [ 0.027 s]
+[INFO] ------------------------------------------------------------------------
+[INFO] BUILD SUCCESS
+[INFO] ------------------------------------------------------------------------
+[INFO] Total time: 0.822 s
+[INFO] Finished at: 2022-02-08T08:57:30+01:00
+[INFO] ------------------------------------------------------------------------
=====================================
pom.xml
=====================================
@@ -6,7 +6,7 @@
<artifactId>sejda-parent</artifactId>
<packaging>pom</packaging>
<name>sejda</name>
- <version>4.2.11</version>
+ <version>4.2.13</version>
<description>An extendible and configurable PDF manipulation layer library. A ready to use java library to perform PDF documents manipulation without having to deal with the low level API. Sejda offers many "ready to go" manipulations implemented using the SAMBox but it can be extended to use other implementations.</description>
<organization>
@@ -32,7 +32,7 @@
<connection>scm:git:git at github.com:torakiki/sejda.git</connection>
<developerConnection>scm:git:git at github.com:torakiki/sejda.git</developerConnection>
<url>scm:git:git at github.com:torakiki/sejda.git</url>
- <tag>v4.2.11</tag>
+ <tag>v4.2.13</tag>
</scm>
<developers>
@@ -378,16 +378,16 @@
<properties>
<sejda.commons.version>1.1.7</sejda.commons.version>
- <junit.version>4.13.1</junit.version>
- <slf4j.version>1.7.30</slf4j.version>
+ <junit.version>5.8.2</junit.version>
+ <slf4j.version>1.7.32</slf4j.version>
<commons.lang.version>3.12.0</commons.lang.version>
<commons.io.version>2.11.0</commons.io.version>
<validation.api.version>1.0.0.GA</validation.api.version>
<mockito.version>4.1.0</mockito.version>
- <logback.version>1.2.8</logback.version>
- <jdepend.version>2.9.1</jdepend.version>
+ <logback.version>1.2.9</logback.version>
+ <archunit.version>0.22.0</archunit.version>
<hibernate-validator.version>4.2.0.Final</hibernate-validator.version>
- <hamcrest.version>1.3</hamcrest.version>
+ <hamcrest.version>2.2</hamcrest.version>
<sambox.version>2.3.4</sambox.version>
<sejda.io.version>2.1.3</sejda.io.version>
<bouncycastle.version>1.70</bouncycastle.version>
@@ -451,18 +451,6 @@
<artifactId>sejda-commons</artifactId>
<version>${sejda.commons.version}</version>
</dependency>
- <dependency>
- <groupId>junit</groupId>
- <artifactId>junit</artifactId>
- <version>${junit.version}</version>
- <scope>test</scope>
- </dependency>
- <dependency>
- <groupId>ch.qos.logback</groupId>
- <artifactId>logback-classic</artifactId>
- <version>${logback.version}</version>
- <scope>test</scope>
- </dependency>
<dependency>
<groupId>org.slf4j</groupId>
<artifactId>slf4j-api</artifactId>
@@ -480,16 +468,34 @@
<version>${sambox.version}</version>
<scope>test</scope>
</dependency>
+ <dependency>
+ <groupId>ch.qos.logback</groupId>
+ <artifactId>logback-classic</artifactId>
+ <version>${logback.version}</version>
+ <scope>test</scope>
+ </dependency>
+ <dependency>
+ <groupId>org.junit.jupiter</groupId>
+ <artifactId>junit-jupiter-engine</artifactId>
+ <version>${junit.version}</version>
+ <scope>test</scope>
+ </dependency>
+ <dependency>
+ <groupId>org.junit.vintage</groupId>
+ <artifactId>junit-vintage-engine</artifactId>
+ <version>${junit.version}</version>
+ <scope>test</scope>
+ </dependency>
<dependency>
<groupId>org.hamcrest</groupId>
- <artifactId>hamcrest-all</artifactId>
+ <artifactId>hamcrest-core</artifactId>
<version>${hamcrest.version}</version>
<scope>test</scope>
</dependency>
<dependency>
- <groupId>jdepend</groupId>
- <artifactId>jdepend</artifactId>
- <version>${jdepend.version}</version>
+ <groupId>com.tngtech.archunit</groupId>
+ <artifactId>archunit-junit5</artifactId>
+ <version>${archunit.version}</version>
<scope>test</scope>
</dependency>
</dependencies>
=====================================
sejda-conversion/pom.xml
=====================================
@@ -10,7 +10,7 @@
<parent>
<groupId>org.sejda</groupId>
<artifactId>sejda-parent</artifactId>
- <version>4.2.11</version>
+ <version>4.2.13</version>
<relativePath>../pom.xml</relativePath>
</parent>
=====================================
sejda-conversion/src/test/java/org/sejda/TestCyclesConversion.java deleted
=====================================
@@ -1,14 +0,0 @@
-package org.sejda;
-
-
-/**
- * Test for cycles.
- *
- * @author Andrea Vacondio
- *
- */
-public class TestCyclesConversion extends TestCycles {
-
- // inherited tests
-
-}
=====================================
sejda-conversion/src/test/java/org/sejda/conversion/TestCycles.java
=====================================
@@ -0,0 +1,20 @@
+package org.sejda.conversion;
+
+import com.tngtech.archunit.junit.AnalyzeClasses;
+import com.tngtech.archunit.junit.ArchTest;
+import com.tngtech.archunit.lang.ArchRule;
+import com.tngtech.archunit.library.dependencies.SlicesRuleDefinition;
+
+/**
+ * Test for cycles.
+ *
+ * @author Andrea Vacondio
+ *
+ */
+ at AnalyzeClasses(packages = "org.sejda")
+public class TestCycles {
+
+ @ArchTest
+ public static final ArchRule myRule = SlicesRuleDefinition.slices().matching("org.sejda.(*)..").should()
+ .beFreeOfCycles();
+}
=====================================
sejda-core/pom.xml
=====================================
@@ -5,7 +5,7 @@
<parent>
<groupId>org.sejda</groupId>
<artifactId>sejda-parent</artifactId>
- <version>4.2.11</version>
+ <version>4.2.13</version>
<relativePath>../pom.xml</relativePath>
</parent>
=====================================
sejda-core/src/test/java/org/sejda/core/TestCyclesCore.java → sejda-core/src/test/java/org/sejda/core/TestCycles.java
=====================================
@@ -19,12 +19,20 @@
*/
package org.sejda.core;
-import org.sejda.TestCycles;
+import com.tngtech.archunit.junit.AnalyzeClasses;
+import com.tngtech.archunit.junit.ArchTest;
+import com.tngtech.archunit.lang.ArchRule;
+import com.tngtech.archunit.library.dependencies.SlicesRuleDefinition;
/**
* @author Andrea Vacondio
*
*/
-public class TestCyclesCore extends TestCycles {
- // inherited
-}
+ at AnalyzeClasses(packages = "org.sejda")
+public class TestCycles {
+
+ @ArchTest
+ public static final ArchRule myRule = SlicesRuleDefinition.slices().matching("org.sejda.(*)..").should()
+ .beFreeOfCycles();
+
+}
\ No newline at end of file
=====================================
sejda-core/src/test/java/org/sejda/core/service/BaseTaskTest.java
=====================================
@@ -172,7 +172,7 @@ public abstract class BaseTaskTest<T extends TaskParameters> implements Testable
public static StreamSource customNonPdfInput(String path) {
String extension = FilenameUtils.getExtension(path);
- String filename = randomAlphanumeric(16) + "." + extension;
+ String filename = new File(path).getName();
return customNonPdfInput(path, filename);
}
=====================================
sejda-core/src/test/resources/image/sample_heic.jpg
=====================================
Binary files /dev/null and b/sejda-core/src/test/resources/image/sample_heic.jpg differ
=====================================
sejda-distribution/pom.xml
=====================================
@@ -10,7 +10,7 @@
<parent>
<groupId>org.sejda</groupId>
<artifactId>sejda-parent</artifactId>
- <version>4.2.11</version>
+ <version>4.2.13</version>
<relativePath>../pom.xml</relativePath>
</parent>
=====================================
sejda-docs/pom.xml
=====================================
@@ -5,7 +5,7 @@
<parent>
<groupId>org.sejda</groupId>
<artifactId>sejda-parent</artifactId>
- <version>4.2.11</version>
+ <version>4.2.13</version>
<relativePath>../pom.xml</relativePath>
</parent>
=====================================
sejda-fonts/pom.xml
=====================================
@@ -10,7 +10,7 @@
<parent>
<groupId>org.sejda</groupId>
<artifactId>sejda-parent</artifactId>
- <version>4.2.11</version>
+ <version>4.2.13</version>
<relativePath>../pom.xml</relativePath>
</parent>
=====================================
sejda-image-writers/pom.xml
=====================================
@@ -6,7 +6,7 @@
<parent>
<groupId>org.sejda</groupId>
<artifactId>sejda-parent</artifactId>
- <version>4.2.11</version>
+ <version>4.2.13</version>
<relativePath>../pom.xml</relativePath>
</parent>
=====================================
sejda-model/pom.xml
=====================================
@@ -6,7 +6,7 @@
<parent>
<groupId>org.sejda</groupId>
<artifactId>sejda-parent</artifactId>
- <version>4.2.11</version>
+ <version>4.2.13</version>
<relativePath>../pom.xml</relativePath>
</parent>
=====================================
sejda-model/src/test/java/org/sejda/TestCycles.java
=====================================
@@ -1,43 +1,19 @@
package org.sejda;
-import java.io.IOException;
-import java.util.ArrayList;
-import java.util.Collection;
-
-import jdepend.framework.JDepend;
-import jdepend.framework.JavaPackage;
-
-import org.junit.Assert;
-import org.junit.Before;
-import org.junit.Test;
-import org.slf4j.Logger;
-import org.slf4j.LoggerFactory;
+import com.tngtech.archunit.junit.AnalyzeClasses;
+import com.tngtech.archunit.junit.ArchTest;
+import com.tngtech.archunit.lang.ArchRule;
+import com.tngtech.archunit.library.dependencies.SlicesRuleDefinition;
/**
* Unit test to test against cycles.
*
- * @author Andrea Vacondio
- * @see http://www.softwarepoets.org/2009/04/unit-tests-to-check-against-cyclic.html
*/
+ at AnalyzeClasses(packages = "org.sejda")
public class TestCycles {
- private static final Logger LOG = LoggerFactory.getLogger(TestCycles.class);
-
- private JDepend jdepend = new JDepend();
- private Collection<? extends Object> packages = new ArrayList<Object>();
-
- @Before
- public void setUp() throws IOException {
- jdepend.addDirectory("target/classes");
- packages = jdepend.analyze();
- }
+ @ArchTest
+ public static final ArchRule myRule = SlicesRuleDefinition.slices().matching("org.sejda.(*)..").should()
+ .beFreeOfCycles();
- @Test
- public void cycleTest() {
- for (Object p : packages) {
- JavaPackage pack1 = (JavaPackage) p;
- Assert.assertFalse(pack1.getName() + " failed.", pack1.containsCycle());
- LOG.debug(String.format("%s analyzed for cycles.", pack1.getName()));
- }
- }
}
=====================================
sejda-sambox/pom.xml
=====================================
@@ -6,7 +6,7 @@
<parent>
<groupId>org.sejda</groupId>
<artifactId>sejda-parent</artifactId>
- <version>4.2.11</version>
+ <version>4.2.13</version>
<relativePath>../pom.xml</relativePath>
</parent>
=====================================
sejda-sambox/src/main/java/org/sejda/impl/sambox/component/PageImageWriter.java
=====================================
@@ -51,6 +51,7 @@ import org.sejda.sambox.pdmodel.PDPageContentStream;
import org.sejda.sambox.pdmodel.graphics.PDXObject;
import org.sejda.sambox.pdmodel.graphics.form.PDFormXObject;
import org.sejda.sambox.pdmodel.graphics.image.PDImageXObject;
+import org.sejda.sambox.pdmodel.graphics.image.UnsupportedImageFormatException;
import org.sejda.sambox.pdmodel.graphics.image.UnsupportedTiffImageException;
import org.sejda.sambox.pdmodel.graphics.state.PDExtendedGraphicsState;
import org.sejda.sambox.util.Matrix;
@@ -123,17 +124,17 @@ public class PageImageWriter {
throws TaskIOException, IOException {
SeekableSource source = original;
- Optional<SeekableSource> maybeConvertedFile = convertExifRotatedIf(source);
+ Optional<SeekableSource> maybeConvertedFile = convertExifRotatedIf(source, name);
if (maybeConvertedFile.isPresent()) {
source = maybeConvertedFile.get();
}
- maybeConvertedFile = convertCMYKJpegIf(source);
+ maybeConvertedFile = convertCMYKJpegIf(source, name);
if (maybeConvertedFile.isPresent()) {
source = maybeConvertedFile.get();
}
- maybeConvertedFile = convertICCGrayPngIf(source);
+ maybeConvertedFile = convertICCGrayPngIf(source, name);
if (maybeConvertedFile.isPresent()) {
source = maybeConvertedFile.get();
}
@@ -196,19 +197,26 @@ public class PageImageWriter {
/**
* Checks if the input file has exit rotation If that's the case, converts to rotated image without exif rotation
*/
- private static Optional<SeekableSource> convertExifRotatedIf(SeekableSource source)
+ private static Optional<SeekableSource> convertExifRotatedIf(SeekableSource source, String name)
throws IOException, TaskIOException {
int degrees = ExifHelper.getRotationBasedOnExifOrientation(source.asNewInputStream());
-
+
if (degrees > 0) {
- BufferedImage result = Thumbnails.of(ImageIO.read(source.asNewInputStream())).scale(1).rotate(degrees)
- .asBufferedImage();
+ BufferedImage orig = ImageIO.read(source.asNewInputStream());
+
+ if(orig == null) {
+ FileType type = FileTypeDetector.detectFileType(source);
+ throw new UnsupportedImageFormatException(type, name, null);
+ }
+
+ BufferedImage result = Thumbnails.of(orig).scale(1).rotate(degrees).asBufferedImage();
- File tmpFile = IOUtils.createTemporaryBuffer();
+ File tmpFile = IOUtils.createTemporaryBufferWithName(name);
ImageIO.write(result, getImageIOSaveFormat(source), tmpFile);
return Optional.of(SeekableSources.seekableSourceFrom(tmpFile));
}
+
return Optional.empty();
}
@@ -224,7 +232,7 @@ public class PageImageWriter {
/**
* Checks if the input file is a JPEG using CMYK If that's the case, converts to RGB and returns the file path
*/
- private static Optional<SeekableSource> convertCMYKJpegIf(SeekableSource source)
+ private static Optional<SeekableSource> convertCMYKJpegIf(SeekableSource source, String name)
throws IOException, TaskIOException {
try {
if (FileType.JPEG.equals(getFileType(source))) {
@@ -247,7 +255,7 @@ public class PageImageWriter {
// twelvemonkeys JPEG plugin already converts it to rgb when reading the image
// just write it out
BufferedImage image = reader.read(0);
- File tmpFile = IOUtils.createTemporaryBuffer();
+ File tmpFile = IOUtils.createTemporaryBufferWithName(name);
ImageIO.write(image, "jpg", tmpFile);
return Optional.of(SeekableSources.seekableSourceFrom(tmpFile));
}
@@ -270,7 +278,7 @@ public class PageImageWriter {
/**
* Checks if the input file is a PNG using ICC Gray color model If that's the case, converts to RGB and returns the file path
*/
- private static Optional<SeekableSource> convertICCGrayPngIf(SeekableSource source)
+ private static Optional<SeekableSource> convertICCGrayPngIf(SeekableSource source, String name)
throws IOException, TaskIOException {
try {
if (FileType.PNG.equals(getFileType(source))) {
@@ -295,7 +303,7 @@ public class PageImageWriter {
// convert to rgb
BufferedImage original = reader.read(0);
BufferedImage rgb = toARGB(original);
- File tmpFile = IOUtils.createTemporaryBuffer();
+ File tmpFile = IOUtils.createTemporaryBufferWithName(name);
ImageIO.write(rgb, "png", tmpFile);
return Optional.of(SeekableSources.seekableSourceFrom(tmpFile));
}
=====================================
sejda-sambox/src/test/java/org/sejda/impl/TestCycles.java
=====================================
@@ -0,0 +1,21 @@
+package org.sejda.impl;
+
+import com.tngtech.archunit.junit.AnalyzeClasses;
+import com.tngtech.archunit.junit.ArchTest;
+import com.tngtech.archunit.lang.ArchRule;
+import com.tngtech.archunit.library.dependencies.SlicesRuleDefinition;
+
+/**
+ * Test for cycles.
+ *
+ * @author Andrea Vacondio
+ *
+ */
+ at AnalyzeClasses(packages = "org.sejda")
+public class TestCycles {
+
+ @ArchTest
+ public static final ArchRule myRule = SlicesRuleDefinition.slices().matching("org.sejda.(*)..").should()
+ .beFreeOfCycles();
+
+}
=====================================
sejda-sambox/src/test/java/org/sejda/impl/TestCyclesSambox.java deleted
=====================================
@@ -1,15 +0,0 @@
-package org.sejda.impl;
-
-import org.sejda.TestCycles;
-
-/**
- * Test for cycles.
- *
- * @author Andrea Vacondio
- *
- */
-public class TestCyclesSambox extends TestCycles {
-
- // inherited tests
-
-}
=====================================
sejda-sambox/src/test/java/org/sejda/impl/sambox/component/PageImageWriterTest.java
=====================================
@@ -20,8 +20,7 @@ package org.sejda.impl.sambox.component;
import static org.hamcrest.MatcherAssert.assertThat;
import static org.hamcrest.Matchers.is;
-import static org.junit.Assert.assertFalse;
-import static org.junit.Assert.assertTrue;
+import static org.junit.Assert.*;
import static org.sejda.TestUtils.encryptedAtRest;
import static org.sejda.core.service.BaseTaskTest.customNonPdfInput;
import static org.sejda.core.service.BaseTaskTest.customNonPdfInputAsFileSource;
@@ -33,6 +32,8 @@ import org.junit.Test;
import org.sejda.model.exception.TaskIOException;
import org.sejda.sambox.pdmodel.graphics.color.PDDeviceRGB;
import org.sejda.sambox.pdmodel.graphics.image.PDImageXObject;
+import org.sejda.sambox.pdmodel.graphics.image.UnsupportedImageFormatException;
+import org.sejda.sambox.util.filetypedetector.FileType;
public class PageImageWriterTest {
@@ -48,6 +49,20 @@ public class PageImageWriterTest {
customNonPdfInput("image/large.jpg").getSource()));
}
+ @Test
+ public void testHeif_unsupported() throws TaskIOException {
+ Exception ex = assertThrows(TaskIOException.class, () -> {
+ PageImageWriter.toPDXImageObject(customNonPdfInput("image/sample_heic.jpg"));
+ });
+
+ Throwable cause = ex.getCause();
+ assertEquals(cause.getClass(), UnsupportedImageFormatException.class);
+ UnsupportedImageFormatException uife = (UnsupportedImageFormatException) cause;
+
+ assertEquals(uife.getFileType(), FileType.HEIF);
+ assertEquals(uife.getFilename(), "sample_heic.jpg");
+ }
+
@Test
public void testPng() throws TaskIOException, IOException {
View it on GitLab: https://salsa.debian.org/java-team/libsejda-java/-/compare/d5c4db6eafd4f1a6562909778146c4d5a3fd060e...020880f6b905f7a681e05c17e1fdba2e811ace25
--
View it on GitLab: https://salsa.debian.org/java-team/libsejda-java/-/compare/d5c4db6eafd4f1a6562909778146c4d5a3fd060e...020880f6b905f7a681e05c17e1fdba2e811ace25
You're receiving this email because of your account on salsa.debian.org.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://alioth-lists.debian.net/pipermail/pkg-java-commits/attachments/20220212/76877b09/attachment.htm>
More information about the pkg-java-commits
mailing list