2021-11-30 02:39:52 +08:00
|
|
|
const { test } = require('@playwright/test');
|
2023-02-14 21:59:46 +08:00
|
|
|
const { SharedNotes } = require('./sharednotes');
|
2021-11-30 02:39:52 +08:00
|
|
|
|
2023-05-13 02:02:27 +08:00
|
|
|
test.describe.parallel('Shared Notes', () => {
|
2023-05-10 00:37:38 +08:00
|
|
|
const sharedNotes = new SharedNotes();
|
|
|
|
|
|
|
|
test.beforeAll(async ({ browser }) => {
|
|
|
|
const context = await browser.newContext();
|
|
|
|
const page = await context.newPage();
|
|
|
|
await sharedNotes.initModPage(page, true);
|
2023-05-13 02:02:27 +08:00
|
|
|
await sharedNotes.initUserPage1(true);
|
2023-05-10 00:37:38 +08:00
|
|
|
});
|
|
|
|
test('Open shared notes @ci', async () => {
|
|
|
|
await sharedNotes.openSharedNotes();
|
|
|
|
});
|
|
|
|
|
|
|
|
test('Type in shared notes', async () => {
|
|
|
|
await sharedNotes.typeInSharedNotes();
|
|
|
|
});
|
|
|
|
|
|
|
|
test('Formate text in shared notes', async () => {
|
|
|
|
await sharedNotes.formatTextInSharedNotes();
|
|
|
|
});
|
|
|
|
|
2023-05-13 02:02:27 +08:00
|
|
|
test('Export shared notes', async ({ context }, testInfo) => {
|
2023-02-16 02:41:21 +08:00
|
|
|
await sharedNotes.exportSharedNotes(testInfo);
|
2022-11-08 00:18:52 +08:00
|
|
|
});
|
2023-05-13 02:02:27 +08:00
|
|
|
|
|
|
|
test('Convert notes to whiteboard', async () => {
|
2022-11-17 02:18:03 +08:00
|
|
|
await sharedNotes.convertNotesToWhiteboard();
|
2022-11-08 00:18:52 +08:00
|
|
|
});
|
2023-05-13 02:02:27 +08:00
|
|
|
|
|
|
|
test('Multiusers edit', async () => {
|
2022-11-08 00:18:52 +08:00
|
|
|
await sharedNotes.editSharedNotesWithMoreThanOneUSer();
|
|
|
|
});
|
2023-05-13 02:02:27 +08:00
|
|
|
|
|
|
|
test('See notes without edit permission', async () => {
|
2022-11-08 00:18:52 +08:00
|
|
|
await sharedNotes.seeNotesWithoutEditPermission();
|
2022-07-21 03:44:09 +08:00
|
|
|
});
|
2023-05-13 02:02:27 +08:00
|
|
|
|
|
|
|
test('Pin notes onto whiteboard', async () => {
|
2022-11-17 02:18:03 +08:00
|
|
|
await sharedNotes.pinNotesOntoWhiteboard();
|
|
|
|
});
|
2021-12-04 01:01:36 +08:00
|
|
|
});
|