use of com.epam.pipeline.manager.MockS3Helper in project cloud-pipeline by epam.
the class DataStorageManagerTest method setUp.
@Before
public void setUp() {
doReturn(new MockS3Helper()).when(storageProviderManager).getS3Helper(any());
Preference systemIndependentBlackList = SystemPreferences.DATA_STORAGE_NFS_MOUNT_BLACK_LIST.toPreference();
systemIndependentBlackList.setValue(Arrays.asList(SystemPreferences.DATA_STORAGE_NFS_MOUNT_BLACK_LIST.getDefaultValue().split(",")).stream().map(p -> Paths.get(p).toString()).collect(Collectors.joining(",")));
preferenceManager.update(Collections.singletonList(systemIndependentBlackList));
}
use of com.epam.pipeline.manager.MockS3Helper in project cloud-pipeline by epam.
the class FolderManagerTest method setUp.
@Before
public void setUp() throws Exception {
awsRegionManager.create(AwsRegionVO.builder().name("US").awsRegionName("us-east-1").isDefault(true).build());
doReturn(new MockS3Helper()).when(storageProviderManager).getS3Helper(any());
folder = new Folder();
folder.setName(TEST_NAME);
subFolder = new Folder();
subFolder.setName(TEST_NAME_1);
MockitoAnnotations.initMocks(this);
when(gitManagerMock.getPipelineRevisions(any(Pipeline.class), any(Long.class))).thenReturn(Collections.emptyList());
pipelineManager.setGitManager(gitManagerMock);
}
use of com.epam.pipeline.manager.MockS3Helper in project cloud-pipeline by epam.
the class FolderTemplateManagerTest method setUp.
@Before
public void setUp() throws Exception {
doReturn(new MockS3Helper()).when(storageProviderManager).getS3Helper(any());
awsRegion = new AwsRegion();
awsRegion.setName("US");
awsRegion.setAwsRegionName("us-east-1");
awsRegion.setDefault(true);
awsRegionDao.create(awsRegion);
AclTestDao.AclSid testUserSid = new AclTestDao.AclSid(true, TEST_USER);
aclTestDao.createAclSid(testUserSid);
AclTestDao.AclSid testRole = new AclTestDao.AclSid(false, TEST_ROLE);
aclTestDao.createAclSid(testRole);
AclTestDao.AclClass folderAclClass = new AclTestDao.AclClass(Folder.class.getCanonicalName());
aclTestDao.createAclClassIfNotPresent(folderAclClass);
}
Aggregations