Browse Source

fix: implement latest playwright changes to multiple-source

Signed-off-by: mertmit <mertmit99@gmail.com>
pull/3573/head
mertmit 2 years ago
parent
commit
6b38c35087
  1. 2
      tests/playwright/pages/Dashboard/Settings/DataSources.ts
  2. 2
      tests/playwright/pages/Dashboard/Settings/Miscellaneous.ts
  3. 10
      tests/playwright/pages/Dashboard/index.ts

2
tests/playwright/pages/Dashboard/Settings/DataSources.ts

@ -20,7 +20,7 @@ export class DataSourcesPage extends BasePage {
} }
get() { get() {
return this.settings.get().locator(`[data-nc="nc-settings-subtab-Data Sources"]`); return this.settings.get().locator(`[data-testid="nc-settings-subtab-Data Sources"]`);
} }
async openErd({ dataSourceName }: { dataSourceName: string }) { async openErd({ dataSourceName }: { dataSourceName: string }) {

2
tests/playwright/pages/Dashboard/Settings/Miscellaneous.ts

@ -10,7 +10,7 @@ export class MiscSettingsPage extends BasePage {
} }
get() { get() {
return this.settings.get().locator(`[data-testid="nc-settings-subtab-Miscellaneous"]`); return this.settings.get().locator(`[data-testid="nc-settings-subtab-Misc"]`);
} }
async clickShowM2MTables() { async clickShowM2MTables() {

10
tests/playwright/pages/Dashboard/index.ts

@ -115,9 +115,13 @@ export class DashboardPage extends BasePage {
await this.get().getByTestId('grid-load-spinner').waitFor({ state: 'hidden' }); await this.get().getByTestId('grid-load-spinner').waitFor({ state: 'hidden' });
if (mode === 'standard') { if (mode === 'standard') {
await expect(this.rootPage).toHaveURL( if (title === 'Team & Auth') {
`/#/nc/${this.project.id}/${title === 'Team & Auth' ? 'auth' : `table/${title}`}` await expect(this.rootPage).toHaveURL(
); `/#/nc/${this.project.id}/auth`
);
} else {
await expect(this.rootPage).toHaveURL(new RegExp(`#\/nc\/${this.project.id}\/table\/md_.{14}`));
}
} }
} }

Loading…
Cancel
Save