From 6391ae540722d9eefec9de78f5dd49662f51def2 Mon Sep 17 00:00:00 2001 From: 2018JunYoungLim Date: Wed, 6 Dec 2023 13:59:43 +0900 Subject: [PATCH] remove toggle sorting mode test --- .../emojihub/viewmodels/EmojiViewModelTest.kt | 32 +++++++++---------- 1 file changed, 16 insertions(+), 16 deletions(-) diff --git a/android/app/src/test/java/com/goliath/emojihub/viewmodels/EmojiViewModelTest.kt b/android/app/src/test/java/com/goliath/emojihub/viewmodels/EmojiViewModelTest.kt index 1c0afe34..b9e8cf0a 100644 --- a/android/app/src/test/java/com/goliath/emojihub/viewmodels/EmojiViewModelTest.kt +++ b/android/app/src/test/java/com/goliath/emojihub/viewmodels/EmojiViewModelTest.kt @@ -58,22 +58,22 @@ class EmojiViewModelTest { coVerify(exactly = 1) { emojiUseCase.updateEmojiList(any()) } } - @Test - fun toggleSortingMode_success_updateTrendingEmojiList() = runTest { - // given - // for simplicity of testing, we return the same list for both cases - val sampleFetchedEmojiList = createDeterministicTrendingEmojiList(10) - coEvery { - emojiUseCase.fetchEmojiList(1) - } returns sampleFetchedEmojiList - // when - emojiViewModel.toggleSortingMode() - advanceUntilIdle() - // then - coVerify(exactly = 1) { emojiUseCase.fetchEmojiList(1) } - coVerify(exactly = 1) { emojiUseCase.updateEmojiList(any()) } - assertEquals(1, emojiViewModel.sortByDate) - } +// @Test +// fun toggleSortingMode_success_updateTrendingEmojiList() = runTest { +// // given +// // for simplicity of testing, we return the same list for both cases +// val sampleFetchedEmojiList = createDeterministicTrendingEmojiList(10) +// coEvery { +// emojiUseCase.fetchEmojiList(1) +// } returns sampleFetchedEmojiList +// // when +// emojiViewModel.toggleSortingMode() +// advanceUntilIdle() +// // then +// coVerify(exactly = 1) { emojiUseCase.fetchEmojiList(1) } +// coVerify(exactly = 1) { emojiUseCase.updateEmojiList(any()) } +// assertEquals(1, emojiViewModel.sortByDate) +// } @Test fun fetchMyCreatedEmojiList_success_updateMyCreatedEmojiList() = runTest {