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

Fix Java Version Dependent Written Unit Tests #542

Open
codeconsole opened this issue Nov 12, 2024 · 0 comments
Open

Fix Java Version Dependent Written Unit Tests #542

codeconsole opened this issue Nov 12, 2024 · 0 comments

Comments

@codeconsole
Copy link
Contributor

codeconsole commented Nov 12, 2024

These test fail with Java 21 21.0.5-librca, but work with 17.0.12-librca

DefaultDateHelperSpec. Full getTimeFormat for style FULL returns 8:00:00 AM Coordinated Universal Time

DefaultDateHelperSpec. for getDateTimeFormat(FULL, FULL) => Sunday, January 5, 1941 at 8:00:00 AM Coordinated Universal Time

format.format(LocalDateTime.of(localDate, localTime)) == expected
|      |      |             |  |          |           |  |
|      |      |             |  1941-01-05 08:00       |  Sunday, January 5, 1941 at 8:00:00 AM Coordinated Universal Time
|      |      |             1941-01-05T08:00          false
|      |      class java.time.LocalDateTime           4 differences (93% similarity)
|      |                                              Sunday, January 5, 1941(,--) 8:00:00( )AM Coordinated Universal Time
|      |                                              Sunday, January 5, 1941( at) 8:00:00( )AM Coordinated Universal Time
|      Sunday, January 5, 1941, 8:00:00 AM Coordinated Universal Time
Localized(FULL,FULL)

the word at

DefaultDateHelperSpec. for getDateTimeFormat(LONG, LONG) => January 5, 1941 at 8:00:00 AM UTC
January 5, 1941 at 8:00:00 AM UTC vs
January 5, 1941, 8:00:00 AM UTC

DefaultDateHelperSpec. for getDateTimeFormat(MEDIUM, MEDIUM) => Jan 5, 1941, 8:00:00 AM
DefaultDateHelperSpec. for getDateTimeFormat(null, null) => 1/5/41, 8:00 AM
DefaultDateHelperSpec. getTimeFormat for style LONG returns 8:00:00 AM UTC
DefaultDateHelperSpec. getTimeFormat for style MEDIUM returns 8:00:00 AM
DefaultDateHelperSpec. getTimeFormat for style null returns 8:00 AM

format.format(localTime) == expected
|      |      |          |  |
|      |      08:00      |  8:00 AM
|      8:00 AM           false
Localized(,SHORT)        1 difference (85% similarity)
                         8:00( )AM
                         8:00( )AM

issue with the space character??

ValidationTagLibSpec. testFieldValueTagWithFrenchLocaleInTextField

@codeconsole codeconsole moved this to Todo in Grails 7 Nov 12, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
Status: Todo
Development

No branches or pull requests

1 participant