Move @Suppress("ktlint:standard:max-line-length") to function scope

pull/1094/head
lihenggui 7 months ago
parent 2a2d8ed88d
commit d671126f9e

@ -44,47 +44,45 @@ class FakeNiaNetworkDataSourceTest {
) )
} }
@Suppress("ktlint:standard:max-line-length")
@Test @Test
fun testDeserializationOfTopics() = fun testDeserializationOfTopics() = runTest(testDispatcher) {
@Suppress("ktlint:standard:max-line-length") assertEquals(
runTest(testDispatcher) { NetworkTopic(
assertEquals( id = "1",
NetworkTopic( name = "Headlines",
id = "1", shortDescription = "News you'll definitely be interested in",
name = "Headlines", longDescription = "The latest events and announcements from the world of Android development.",
shortDescription = "News you'll definitely be interested in", url = "",
longDescription = "The latest events and announcements from the world of Android development.", imageUrl = "https://firebasestorage.googleapis.com/v0/b/now-in-android.appspot.com/o/img%2Fic_topic_Headlines.svg?alt=media&token=506faab0-617a-4668-9e63-4a2fb996603f",
url = "", ),
imageUrl = "https://firebasestorage.googleapis.com/v0/b/now-in-android.appspot.com/o/img%2Fic_topic_Headlines.svg?alt=media&token=506faab0-617a-4668-9e63-4a2fb996603f", subject.getTopics().first(),
), )
subject.getTopics().first(), }
)
}
@Suppress("ktlint:standard:max-line-length")
@Test @Test
fun testDeserializationOfNewsResources() = fun testDeserializationOfNewsResources() = runTest(testDispatcher) {
@Suppress("ktlint:standard:max-line-length") assertEquals(
runTest(testDispatcher) { NetworkNewsResource(
assertEquals( id = "125",
NetworkNewsResource( title = "Android Basics with Compose",
id = "125", content = "We released the first two units of Android Basics with Compose, our first free course that teaches Android Development with Jetpack Compose to anyone; you do not need any prior programming experience other than basic computer literacy to get started. ",
title = "Android Basics with Compose", url = "https://android-developers.googleblog.com/2022/05/new-android-basics-with-compose-course.html",
content = "We released the first two units of Android Basics with Compose, our first free course that teaches Android Development with Jetpack Compose to anyone; you do not need any prior programming experience other than basic computer literacy to get started. ", headerImageUrl = "https://developer.android.com/images/hero-assets/android-basics-compose.svg",
url = "https://android-developers.googleblog.com/2022/05/new-android-basics-with-compose-course.html", publishDate = LocalDateTime(
headerImageUrl = "https://developer.android.com/images/hero-assets/android-basics-compose.svg", year = 2022,
publishDate = LocalDateTime( monthNumber = 5,
year = 2022, dayOfMonth = 4,
monthNumber = 5, hour = 23,
dayOfMonth = 4, minute = 0,
hour = 23, second = 0,
minute = 0, nanosecond = 0,
second = 0, ).toInstant(TimeZone.UTC),
nanosecond = 0, type = "Codelab",
).toInstant(TimeZone.UTC), topics = listOf("2", "3", "10"),
type = "Codelab", ),
topics = listOf("2", "3", "10"), subject.getNewsResources().find { it.id == "125" },
), )
subject.getNewsResources().find { it.id == "125" }, }
)
}
} }

Loading…
Cancel
Save