Skip to content

Commit

Permalink
fli-iam#2488 : Tests modified for allowing download class heredity with
Browse files Browse the repository at this point in the history
  • Loading branch information
DuckflipXYZ committed Dec 2, 2024
1 parent 297298a commit 3a966a5
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -56,6 +56,7 @@
import org.shanoir.ng.utils.usermock.WithMockKeycloakUser;
import org.springframework.amqp.rabbit.core.RabbitTemplate;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.beans.factory.annotation.Qualifier;
import org.springframework.boot.test.autoconfigure.web.servlet.AutoConfigureMockMvc;
import org.springframework.boot.test.autoconfigure.web.servlet.WebMvcTest;
import org.springframework.boot.test.mock.mockito.MockBean;
Expand Down Expand Up @@ -154,6 +155,7 @@ public class DatasetApiControllerTest {
private DicomSEGAndSRImporterService dicomSRImporterService;

@MockBean
@Qualifier("datasetDownloaderServiceImpl")
private DatasetDownloaderServiceImpl datasetDownloaderService;

@MockBean
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -40,6 +40,7 @@
import org.shanoir.ng.shared.security.ControlerSecurityService;
import org.shanoir.ng.utils.usermock.WithMockKeycloakUser;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.beans.factory.annotation.Qualifier;
import org.springframework.boot.test.context.SpringBootTest;
import org.springframework.boot.test.mock.mockito.MockBean;
import org.springframework.mock.web.MockHttpServletResponse;
Expand All @@ -61,10 +62,11 @@
@SpringBootTest
@ActiveProfiles("test")
public class DatasetDownloaderServiceTest {

@Autowired

@Qualifier("datasetDownloaderServiceImpl")
@Autowired
DatasetDownloaderServiceImpl datasetDownloaderService;

@MockBean
private DatasetService datasetServiceMock;

Expand Down

0 comments on commit 3a966a5

Please sign in to comment.