You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
26 lines
667 B
26 lines
667 B
import { AppConfigPage, AppPage, test as base } from '@grafana/plugin-e2e'; |
|
import pluginJson from '../src/plugin.json'; |
|
|
|
type AppTestFixture = { |
|
appConfigPage: AppConfigPage; |
|
gotoPage: (path?: string) => Promise<AppPage>; |
|
}; |
|
|
|
export const test = base.extend<AppTestFixture>({ |
|
appConfigPage: async ({ gotoAppConfigPage }, use) => { |
|
const configPage = await gotoAppConfigPage({ |
|
pluginId: pluginJson.id, |
|
}); |
|
await use(configPage); |
|
}, |
|
gotoPage: async ({ gotoAppPage }, use) => { |
|
await use((path) => |
|
gotoAppPage({ |
|
path, |
|
pluginId: pluginJson.id, |
|
}) |
|
); |
|
}, |
|
}); |
|
|
|
export { expect } from '@grafana/plugin-e2e';
|
|
|