Skip to content

Commit

Permalink
fix: failing tests issue fixed
Browse files Browse the repository at this point in the history
  • Loading branch information
“sneha122” committed Oct 25, 2024
1 parent 3b5e6c7 commit 95cc7e7
Showing 1 changed file with 2 additions and 6 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -48,6 +48,7 @@
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.boot.test.context.SpringBootTest;
import org.springframework.boot.test.mock.mockito.MockBean;
import org.springframework.boot.test.mock.mockito.SpyBean;
import org.springframework.security.test.context.support.WithUserDetails;
import org.springframework.test.annotation.DirtiesContext;
import reactor.core.publisher.Mono;
Expand Down Expand Up @@ -135,7 +136,7 @@ public class ActionCollectionServiceTest {
@MockBean
PluginExecutor pluginExecutor;

@MockBean
@SpyBean
UpdateLayoutService updateLayoutService;

Application testApp = null;
Expand Down Expand Up @@ -743,11 +744,6 @@ public void testUpdateUnpublishedActionCollection_withValidCollection_callsPageL

actionCollectionDTO.setActions(List.of(action1, action2, action3));

Mockito.when(updateLayoutService.updatePageLayoutsByPageId(Mockito.anyString()))
.thenAnswer(invocationOnMock -> {
return Mono.just(testPage.getId());
});

ActionCollectionDTO createdActionCollectionDTO =
layoutCollectionService.createCollection(actionCollectionDTO).block();
assert createdActionCollectionDTO != null;
Expand Down

0 comments on commit 95cc7e7

Please sign in to comment.