mirror of
https://github.com/Alfresco/alfresco-content-app.git
synced 2025-05-12 17:04:46 +00:00
some more little fixes
This commit is contained in:
parent
e8e353fd48
commit
7adba9e619
@ -124,7 +124,7 @@ describe('Mark items as favorites', () => {
|
|||||||
try {
|
try {
|
||||||
await apis.user.favorites.addFavoritesByIds('file', [ fileFavUIId, fileFav1Id, fileFav2Id, fileFav3Id, fileFav4Id ]);
|
await apis.user.favorites.addFavoritesByIds('file', [ fileFavUIId, fileFav1Id, fileFav2Id, fileFav3Id, fileFav4Id ]);
|
||||||
await apis.user.favorites.addFavoriteById('folder', folderId);
|
await apis.user.favorites.addFavoriteById('folder', folderId);
|
||||||
await apis.user.favorites.removeFavoritesByIds([ fileNotFavUIId , fileNotFav1Id, fileNotFav2Id, fileNotFav3Id, fileNotFav4Id ]);
|
await apis.user.favorites.removeFavoritesByIds([ fileNotFav1Id, fileNotFav2Id, fileNotFav3Id, fileNotFav4Id ]);
|
||||||
await apis.user.favorites.waitForApi({ expect: 10 });
|
await apis.user.favorites.waitForApi({ expect: 10 });
|
||||||
} catch (error) {
|
} catch (error) {
|
||||||
}
|
}
|
||||||
@ -321,7 +321,6 @@ describe('Mark items as favorites', () => {
|
|||||||
afterAll(async (done) => {
|
afterAll(async (done) => {
|
||||||
try {
|
try {
|
||||||
await apis.user.favorites.addFavoritesByIds('file', [ fileFav1Id, fileFav2Id, fileFav3Id, fileFav4Id ]);
|
await apis.user.favorites.addFavoritesByIds('file', [ fileFav1Id, fileFav2Id, fileFav3Id, fileFav4Id ]);
|
||||||
await apis.user.favorites.removeFavoritesByIds([ fileNotFav1Id, fileNotFav2Id, fileNotFav3Id, fileNotFav4Id ]);
|
|
||||||
await apis.user.favorites.waitForApi({ expect: 10 });
|
await apis.user.favorites.waitForApi({ expect: 10 });
|
||||||
} catch (error) {
|
} catch (error) {
|
||||||
}
|
}
|
||||||
|
@ -459,6 +459,7 @@ describe('Viewer actions', () => {
|
|||||||
|
|
||||||
beforeAll(async (done) => {
|
beforeAll(async (done) => {
|
||||||
await apis.user.search.waitForApi(username, {expect: 0});
|
await apis.user.search.waitForApi(username, {expect: 0});
|
||||||
|
|
||||||
parentId = (await apis.user.nodes.createFolder(parent)).entry.id;
|
parentId = (await apis.user.nodes.createFolder(parent)).entry.id;
|
||||||
destinationId = (await apis.user.nodes.createFolder(destination)).entry.id;
|
destinationId = (await apis.user.nodes.createFolder(destination)).entry.id;
|
||||||
docxFileId = (await apis.user.upload.uploadFileWithRename(docxFile, parentId, docxRecentFiles)).entry.id;
|
docxFileId = (await apis.user.upload.uploadFileWithRename(docxFile, parentId, docxRecentFiles)).entry.id;
|
||||||
@ -476,7 +477,7 @@ describe('Viewer actions', () => {
|
|||||||
await apis.user.upload.uploadFileWithRename(xlsxFileForMove, parentId, xlsxRecentFiles);
|
await apis.user.upload.uploadFileWithRename(xlsxFileForMove, parentId, xlsxRecentFiles);
|
||||||
await apis.user.upload.uploadFileWithRename(pdfFileForDelete, parentId, pdfRecentFiles);
|
await apis.user.upload.uploadFileWithRename(pdfFileForDelete, parentId, pdfRecentFiles);
|
||||||
|
|
||||||
await apis.user.search.waitForApi(username, {expect: 8});
|
await apis.user.search.waitForApi(username, {expect: 7});
|
||||||
|
|
||||||
await loginPage.loginWith(username);
|
await loginPage.loginWith(username);
|
||||||
done();
|
done();
|
||||||
@ -654,9 +655,8 @@ describe('Viewer actions', () => {
|
|||||||
await apis.user.nodes.lockFile(fileForCancelEditingId);
|
await apis.user.nodes.lockFile(fileForCancelEditingId);
|
||||||
await apis.user.nodes.lockFile(fileForUploadNewVersionId);
|
await apis.user.nodes.lockFile(fileForUploadNewVersionId);
|
||||||
|
|
||||||
|
|
||||||
await apis.user.shared.shareFilesByIds([docxFileId, xlsxFileId, pdfFileId, fileForCancelEditingId, fileForEditOfflineId, fileForUploadNewVersionId, fileSharedId])
|
await apis.user.shared.shareFilesByIds([docxFileId, xlsxFileId, pdfFileId, fileForCancelEditingId, fileForEditOfflineId, fileForUploadNewVersionId, fileSharedId])
|
||||||
await apis.user.shared.waitForApi({expect: 8});
|
await apis.user.shared.waitForApi({expect: 7});
|
||||||
|
|
||||||
await loginPage.loginWith(username);
|
await loginPage.loginWith(username);
|
||||||
done();
|
done();
|
||||||
@ -668,6 +668,7 @@ describe('Viewer actions', () => {
|
|||||||
});
|
});
|
||||||
|
|
||||||
afterEach(async (done) => {
|
afterEach(async (done) => {
|
||||||
|
await page.closeOpenDialogs();
|
||||||
await Utils.pressEscape();
|
await Utils.pressEscape();
|
||||||
done();
|
done();
|
||||||
});
|
});
|
||||||
@ -837,7 +838,7 @@ describe('Viewer actions', () => {
|
|||||||
|
|
||||||
|
|
||||||
await apis.user.favorites.addFavoritesByIds('file', [docxFileId, xlsxFileId, pdfFileId, fileForEditOfflineId, fileForCancelEditingId, fileForUploadNewVersionId, fileFavId])
|
await apis.user.favorites.addFavoritesByIds('file', [docxFileId, xlsxFileId, pdfFileId, fileForEditOfflineId, fileForCancelEditingId, fileForUploadNewVersionId, fileFavId])
|
||||||
await apis.user.favorites.waitForApi({expect: 8});
|
await apis.user.favorites.waitForApi({expect: 7});
|
||||||
|
|
||||||
await loginPage.loginWith(username);
|
await loginPage.loginWith(username);
|
||||||
done();
|
done();
|
||||||
|
@ -50,7 +50,7 @@ export abstract class RepoApi {
|
|||||||
|
|
||||||
protected handleError(message: string, response: any) {
|
protected handleError(message: string, response: any) {
|
||||||
console.log(`\n--- ${message} error :`);
|
console.log(`\n--- ${message} error :`);
|
||||||
if ( response.status ) {
|
if ( response.status && response.response ) {
|
||||||
try {
|
try {
|
||||||
console.log('\t>>> Status: ', response.status);
|
console.log('\t>>> Status: ', response.status);
|
||||||
console.log('\t>>> Text: ', response.response.text);
|
console.log('\t>>> Text: ', response.response.text);
|
||||||
|
Loading…
x
Reference in New Issue
Block a user