use of ca.corefacility.bioinformatics.irida.repositories.user.UserRepository in project irida by phac-nml.
the class ProjectServiceImplTest method setUp.
@Before
public void setUp() {
validator = mock(Validator.class);
projectRepository = mock(ProjectRepository.class);
sampleRepository = mock(SampleRepository.class);
userRepository = mock(UserRepository.class);
pujRepository = mock(ProjectUserJoinRepository.class);
psjRepository = mock(ProjectSampleJoinRepository.class);
relatedProjectRepository = mock(RelatedProjectRepository.class);
referenceFileRepository = mock(ReferenceFileRepository.class);
prfjRepository = mock(ProjectReferenceFileJoinRepository.class);
ugpjRepository = mock(UserGroupProjectJoinRepository.class);
sequencingObjectRepository = mock(SequencingObjectRepository.class);
projectService = new ProjectServiceImpl(projectRepository, sampleRepository, userRepository, pujRepository, psjRepository, relatedProjectRepository, referenceFileRepository, prfjRepository, ugpjRepository, ssoRepository, pasRepository, sequencingObjectRepository, validator);
}
use of ca.corefacility.bioinformatics.irida.repositories.user.UserRepository in project irida by phac-nml.
the class PasswordExpiryCheckerTest method setUp.
@Before
public void setUp() {
userRepository = mock(UserRepository.class);
checker = new PasswordExpiryChecker(userRepository, 5);
user = new User();
user.setId(1L);
user.setUsername("bob");
revUser = new User();
revUser.setId(1L);
revUser.setUsername("bob");
when(userRepository.loadUserByUsername(user.getUsername())).thenReturn(user);
}
use of ca.corefacility.bioinformatics.irida.repositories.user.UserRepository in project irida by phac-nml.
the class ReadProjectPermissionTest method setUp.
@Before
public void setUp() {
userRepository = mock(UserRepository.class);
projectRepository = mock(ProjectRepository.class);
pujRepository = mock(ProjectUserJoinRepository.class);
ugpjRepository = mock(UserGroupProjectJoinRepository.class);
ugRepository = mock(UserGroupJoinRepository.class);
readProjectPermission = new ReadProjectPermission(projectRepository, userRepository, pujRepository, ugpjRepository, ugRepository);
}
use of ca.corefacility.bioinformatics.irida.repositories.user.UserRepository in project irida by phac-nml.
the class UpdateUserPermissionTest method setUp.
@Before
public void setUp() {
userRepository = mock(UserRepository.class);
updateUserPermission = new UpdateUserPermission(userRepository);
}
use of ca.corefacility.bioinformatics.irida.repositories.user.UserRepository in project irida by phac-nml.
the class ReadSequencingObjectPermissionTest method setUp.
@Before
public void setUp() {
userRepository = mock(UserRepository.class);
ssoRepository = mock(SampleSequencingObjectJoinRepository.class);
sequencingObjectRepository = mock(SequencingObjectRepository.class);
psjRepository = mock(ProjectSampleJoinRepository.class);
sampleRepository = mock(SampleRepository.class);
readProjectPermission = mock(ReadProjectPermission.class);
samplePermission = new ReadSamplePermission(sampleRepository, psjRepository, readProjectPermission);
permission = new ReadSequencingObjectPermission(sequencingObjectRepository, samplePermission, ssoRepository);
}
Aggregations