Ensure consistent AggregatedReaction screenshots

Different system locales can generate different screenshots, causing CI
to be unhappy. Hardcoding a locale ensures the same date format is
always used.

Signed-off-by: Joe Groocock <me@frebib.net>
This commit is contained in:
Joe Groocock 2024-08-22 10:35:19 +01:00
parent 1b7c0dbe88
commit 0f14bc1a1c
No known key found for this signature in database
GPG key ID: A5571FCDC53ADDE6
3 changed files with 6 additions and 6 deletions

View file

@ -38,10 +38,10 @@ fun anAggregatedReaction(
count: Int = 1,
isHighlighted: Boolean = false,
): AggregatedReaction {
val timeFormatter = DateFormat.getTimeInstance(DateFormat.SHORT, java.util.Locale.US)
val date = Date(1_689_061_264L)
val senders = buildList {
repeat(count) { index ->
val timeFormatter = DateFormat.getTimeInstance(DateFormat.SHORT)
val date = Date(1_689_061_264L)
add(
AggregatedReactionSender(
senderId = if (isHighlighted && index == 0) userId else UserId("@user$index:server.org"),