From e20981d083387ea4cf183325a7bfc7bbcfbd592e Mon Sep 17 00:00:00 2001 From: Jason Ross Date: Wed, 1 Jul 2026 15:15:24 -0500 Subject: [PATCH] style(test): satisfy ktlint in new folder-label tests Body expression on the signature line (function-signature) and one argument per wrapped line (argument-list-wrapping) in the tests added for drawer folder de-duplication. Co-Authored-By: Claude Opus 4.8 --- .../data/local/LibreMailDatabaseTest.kt | 9 +++++++-- .../libremail/ui/mailbox/FolderLabelsTest.kt | 17 ++++++++--------- 2 files changed, 15 insertions(+), 11 deletions(-) diff --git a/app/src/androidTest/kotlin/org/libremail/data/local/LibreMailDatabaseTest.kt b/app/src/androidTest/kotlin/org/libremail/data/local/LibreMailDatabaseTest.kt index 3019b28..61ce90d 100644 --- a/app/src/androidTest/kotlin/org/libremail/data/local/LibreMailDatabaseTest.kt +++ b/app/src/androidTest/kotlin/org/libremail/data/local/LibreMailDatabaseTest.kt @@ -133,8 +133,13 @@ class LibreMailDatabaseTest { "acct", listOf( FolderEntity( - "acct", "[Gmail]/Sent Mail", "Sent Mail", "SENT", - selectable = true, sortOrder = 1, specialUse = true, + accountId = "acct", + fullName = "[Gmail]/Sent Mail", + displayName = "Sent Mail", + role = "SENT", + selectable = true, + sortOrder = 1, + specialUse = true, ), FolderEntity("acct", "INBOX", "INBOX", "INBOX", selectable = true, sortOrder = 0), ), diff --git a/app/src/test/kotlin/org/libremail/ui/mailbox/FolderLabelsTest.kt b/app/src/test/kotlin/org/libremail/ui/mailbox/FolderLabelsTest.kt index ef4c4da..65644ed 100644 --- a/app/src/test/kotlin/org/libremail/ui/mailbox/FolderLabelsTest.kt +++ b/app/src/test/kotlin/org/libremail/ui/mailbox/FolderLabelsTest.kt @@ -19,15 +19,14 @@ class FolderLabelsTest { specialUse: Boolean = false, ) = Folder("acct", fullName, displayName, role, selectable = true, specialUse = specialUse) - private fun account(email: String, imapHost: String, authType: AuthType = AuthType.PASSWORD_IMAP) = - Account( - id = "acct", - email = email, - displayName = email, - authType = authType, - imap = ServerConfig(imapHost, 993, MailSecurity.SSL_TLS), - smtp = ServerConfig("smtp", 587, MailSecurity.STARTTLS), - ) + private fun account(email: String, imapHost: String, authType: AuthType = AuthType.PASSWORD_IMAP) = Account( + id = "acct", + email = email, + displayName = email, + authType = authType, + imap = ServerConfig(imapHost, 993, MailSecurity.SSL_TLS), + smtp = ServerConfig("smtp", 587, MailSecurity.STARTTLS), + ) /** Builds base labels the way the drawer does: the friendly role name, else the raw display name. */ private fun baseLabelsOf(folders: List, friendly: Map) =