Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

AWT TS: Use test suite own fonts for tests, not system ones #22755

Merged
merged 1 commit into from
Jan 9, 2022

Conversation

Karm
Copy link
Member

@Karm Karm commented Jan 8, 2022

fixes #22652

The test suite relied on system fonts in some parts and that is fragile, prone to false positives if the system does not have those fonts installed. This PR changes that so as only those renders done with test suite's own fonts are tested.

It also adds meaningful exceptions when unsupported font types are used.

@quarkus-bot
Copy link

quarkus-bot bot commented Jan 8, 2022

/cc @galderz, @zakkak

@quarkus-bot
Copy link

quarkus-bot bot commented Jan 9, 2022

This workflow status is outdated as a new workflow run has been triggered.

Failing Jobs - Building c97a680

Status Name Step Failures Logs Raw logs
✔️ JVM Tests - JDK 11
JVM Tests - JDK 17 Build Failures Logs Raw logs

Full information is available in the Build summary check run.

Failures

⚙️ JVM Tests - JDK 17 #

- Failing: integration-tests/awt 

📦 integration-tests/awt

io.quarkus.awt.it.ImageGeometryFontsTest.testGeometryAndFonts(String)[1] line 89 - More details - Source on GitHub

org.opentest4j.AssertionFailedError: TIFF: Wrong pixel at 94x92. Expected: [0,0,0,255] Actual: [194,33,132,255] ==> expected: <true> but was: <false>
	at org.junit.jupiter.api.AssertionUtils.fail(AssertionUtils.java:55)
	at org.junit.jupiter.api.AssertTrue.assertTrue(AssertTrue.java:40)

io.quarkus.awt.it.ImageGeometryFontsTest.testGeometryAndFonts(String)[2] line 89 - More details - Source on GitHub

org.opentest4j.AssertionFailedError: GIF: Wrong pixel at 94x92. Expected: [0,0,0,0] Actual: [161,0,0,0] ==> expected: <true> but was: <false>
	at org.junit.jupiter.api.AssertionUtils.fail(AssertionUtils.java:55)
	at org.junit.jupiter.api.AssertTrue.assertTrue(AssertTrue.java:40)

io.quarkus.awt.it.ImageGeometryFontsTest.testGeometryAndFonts(String)[3] line 89 - More details - Source on GitHub

org.opentest4j.AssertionFailedError: PNG: Wrong pixel at 94x92. Expected: [0,0,0,255] Actual: [194,33,132,255] ==> expected: <true> but was: <false>
	at org.junit.jupiter.api.AssertionUtils.fail(AssertionUtils.java:55)
	at org.junit.jupiter.api.AssertTrue.assertTrue(AssertTrue.java:40)

io.quarkus.awt.it.ImageGeometryFontsTest.testGeometryAndFonts(String)[4] line 89 - More details - Source on GitHub

org.opentest4j.AssertionFailedError: JPG: Wrong pixel at 94x92. Expected: [42,0,23,0] Actual: [192,34,129,0] ==> expected: <true> but was: <false>
	at org.junit.jupiter.api.AssertionUtils.fail(AssertionUtils.java:55)
	at org.junit.jupiter.api.AssertTrue.assertTrue(AssertTrue.java:40)

io.quarkus.awt.it.ImageGeometryFontsTest.testGeometryAndFonts(String)[5] line 89 - More details - Source on GitHub

org.opentest4j.AssertionFailedError: BMP: Wrong pixel at 94x92. Expected: [0,0,0,0] Actual: [194,33,132,0] ==> expected: <true> but was: <false>
	at org.junit.jupiter.api.AssertionUtils.fail(AssertionUtils.java:55)
	at org.junit.jupiter.api.AssertTrue.assertTrue(AssertTrue.java:40)

@Karm
Copy link
Member Author

Karm commented Jan 9, 2022

Ah, JDK17 case, lemme refactor...

@Karm Karm marked this pull request as draft January 9, 2022 08:38
@Karm Karm force-pushed the awt-tolerant-pixels branch from c97a680 to 3e215ba Compare January 9, 2022 10:26
@Karm Karm marked this pull request as ready for review January 9, 2022 10:27
@gsmet gsmet merged commit 0cd6321 into quarkusio:main Jan 9, 2022
@quarkus-bot quarkus-bot bot added this to the 2.7 - main milestone Jan 9, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

AWT integration tests: Native: False positives on systems with older libs (fontconfig ?)
2 participants