Skip to content

Commit

Permalink
chore: adjust tests after powermock upgrade
Browse files Browse the repository at this point in the history
  • Loading branch information
tkuzynow committed Jan 3, 2025
1 parent 592f0ae commit 8432c5c
Showing 1 changed file with 1 addition and 8 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -33,6 +33,7 @@
import org.mockito.Mock;
import org.mockito.junit.jupiter.MockitoExtension;
import org.slf4j.Logger;
import org.springframework.test.util.ReflectionTestUtils;

@ExtendWith(MockitoExtension.class)
public class InactivePrivateGroupsProviderTest {
Expand All @@ -41,12 +42,6 @@ public class InactivePrivateGroupsProviderTest {

@Mock private RocketChatService rocketChatService;
@Mock private ChatRepository chatRepository;
@Mock private Logger logger;

@BeforeEach
public void setup() {
setInternalState(LogService.class, "LOGGER", logger);
}

@Test
public void
Expand Down Expand Up @@ -95,10 +90,8 @@ public void retrieveUserWithInactiveGroupsMap_ShouldLogError_WhenFetchOfInactive
doThrow(new RocketChatGetGroupsListAllException(new RuntimeException()))
.when(this.rocketChatService)
.fetchAllInactivePrivateGroupsSinceGivenDate(any());

inactivePrivateGroupsProvider.retrieveUserWithInactiveGroupsMap();

verify(this.logger, times(1)).error(anyString(), anyString(), anyString(), anyString());
}

@Test
Expand Down

0 comments on commit 8432c5c

Please sign in to comment.