use of com.owncloud.android.test.ui.models.FileListView in project android by owncloud.
the class ShareLinkFileTestSuite method testUnshareLinkFile.
@Test
@Category({ IgnoreTestCategory.class, SmokeTestCategory.class })
public void testUnshareLinkFile() throws Exception {
AndroidElement sharedElementIndicator;
FileListView fileListView = Actions.login(Config.URL, Config.user, Config.password, Config.isTrusted, driver);
common.assertIsInFileListView();
//TODO. if the file already exists, do not upload
FileListView fileListViewAfterUploadFile = Actions.uploadFile(FILE_NAME, fileListView);
fileListViewAfterUploadFile.scrollTillFindElement(FILE_NAME);
assertTrue(fileHasBeenCreated = fileListViewAfterUploadFile.getFileElement().isDisplayed());
sharedElementIndicator = Actions.shareLinkElementByCopyLink(FILE_NAME, fileListViewAfterUploadFile, driver, common);
assertTrue(sharedElementIndicator.isDisplayed());
Actions.unshareLinkElement(FILE_NAME, fileListViewAfterUploadFile, driver, common);
assertFalse(sharedElementIndicator.isDisplayed());
}
use of com.owncloud.android.test.ui.models.FileListView in project android by owncloud.
the class ShareLinkFileTestSuite method testShareLinkFileByCopyLink.
@Test
@Category({ NoIgnoreTestCategory.class, SmokeTestCategory.class })
public void testShareLinkFileByCopyLink() throws Exception {
AndroidElement sharedElementIndicator;
FileListView fileListView = Actions.login(Config.URL, Config.user, Config.password, Config.isTrusted, driver);
common.assertIsInFileListView();
//TODO. if the file already exists, do not upload
FileListView fileListViewAfterUploadFile = Actions.uploadFile(FILE_NAME, fileListView);
fileListViewAfterUploadFile.scrollTillFindElement(FILE_NAME);
assertTrue(fileHasBeenCreated = fileListViewAfterUploadFile.getFileElement().isDisplayed());
sharedElementIndicator = Actions.shareLinkElementByCopyLink(FILE_NAME, fileListViewAfterUploadFile, driver, common);
assertTrue(sharedElementIndicator.isDisplayed());
}
use of com.owncloud.android.test.ui.models.FileListView in project android by owncloud.
the class ShareLinkFileTestSuite method testShareLinkFileByGmail.
@Test
@Category({ NoIgnoreTestCategory.class })
public void testShareLinkFileByGmail() throws Exception {
AndroidElement sharedElementIndicator;
FileListView fileListView = Actions.login(Config.URL, Config.user, Config.password, Config.isTrusted, driver);
common.assertIsInFileListView();
//TODO. if the file already exists, do not upload
FileListView fileListViewAfterUploadFile = Actions.uploadFile(FILE_NAME, fileListView);
fileListViewAfterUploadFile.scrollTillFindElement(FILE_NAME);
assertTrue(fileHasBeenCreated = fileListViewAfterUploadFile.getFileElement().isDisplayed());
sharedElementIndicator = Actions.shareLinkElementByGmail(FILE_NAME, fileListViewAfterUploadFile, driver, common);
assertTrue(sharedElementIndicator.isDisplayed());
}
use of com.owncloud.android.test.ui.models.FileListView in project android by owncloud.
the class UploadTestSuite method tearDown.
@After
public void tearDown() throws Exception {
common.takeScreenShotOnFailed(name.getMethodName());
FileListView fileListView = new FileListView(driver);
if (fileHasBeenUploadedFromGmail) {
Actions.deleteElement(FILE_GMAIL_NAME, fileListView, driver);
}
if (fileHasBeenUploaded) {
Actions.deleteElement(FILE_NAME, fileListView, driver);
Actions.deleteElement(BIG_FILE_NAME, fileListView, driver);
}
//driver.removeApp("com.owncloud.android");
driver.quit();
}
use of com.owncloud.android.test.ui.models.FileListView in project android by owncloud.
the class CreateFolderTestSuite method tearDown.
@After
public void tearDown() throws Exception {
common.takeScreenShotOnFailed(name.getMethodName());
if (folderHasBeenCreated) {
FileListView fileListView = new FileListView(driver);
Actions.deleteElement(CurrentCreatedFolder, fileListView, driver);
}
driver.removeApp("com.owncloud.android");
driver.quit();
}
Aggregations