Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 4 additions & 4 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

3 changes: 3 additions & 0 deletions packages/plugin-e2e/docker-compose.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,9 @@ services:
- GF_AUTH_ANONYMOUS_ORG_NAME=Main Org.
- GF_AUTH_ANONYMOUS_ORG_ID=1
- GF_PANELS_ENABLE_ALPHA=true
- GF_FEATURE_TOGGLES_splashScreen=false
# TODO we need to handle new layouts in the e2e tests!
- GF_FEATURE_TOGGLES_dashboardNewLayouts=false
ports:
- 3000:3000/tcp
volumes:
Expand Down
2 changes: 1 addition & 1 deletion packages/plugin-e2e/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,7 @@
"dotenv": "^17.2.4"
},
"dependencies": {
"@grafana/e2e-selectors": "13.0.0-23624974663",
"@grafana/e2e-selectors": "13.1.0-24236083202",
"semver": "^7.5.4",
"uuid": "^13.0.0",
"yaml": "^2.3.4"
Comment on lines 50 to 55
Copy link

Copilot AI Apr 9, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@grafana/e2e-selectors was bumped here, but the repo-level package-lock.json still pins the previous version. This will cause CI installs to keep using the old selectors unless the lockfile is updated (run npm install / update the lockfile).

Copilot uses AI. Check for mistakes.
Expand Down
5 changes: 4 additions & 1 deletion packages/plugin-e2e/src/models/pages/AlertRuleEditPage.ts
Original file line number Diff line number Diff line change
Expand Up @@ -95,7 +95,10 @@ export class AlertRuleEditPage extends GrafanaPage {

if (advancedModeSupported && !(await this.advancedModeSwitch.isChecked()) && refId === 'A') {
// return the default query row
return new AlertRuleQuery(this.ctx, this.ctx.page.getByTestId('query-editor-row'));
return new AlertRuleQuery(
this.ctx,
this.getByGrafanaSelector(this.ctx.selectors.components.QueryEditorRows.rows)
Copy link

Copilot AI Apr 9, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

In the advanced-mode-disabled branch, QueryEditorRows.rows is passed directly as the query root. Since this selector represents a collection of rows (used elsewhere with .filter()/.last()), this can unintentionally target multiple rows and later actions may fail Playwright strictness or operate on the wrong row. Narrow the locator to a single row (e.g. .first()), or otherwise uniquely identify the default row.

Suggested change
this.getByGrafanaSelector(this.ctx.selectors.components.QueryEditorRows.rows)
this.getByGrafanaSelector(this.ctx.selectors.components.QueryEditorRows.rows).first()

Copilot uses AI. Check for mistakes.
);
}

// return query by refId
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -108,7 +108,7 @@ test('enter value in number input', async ({ gotoPanelEditPage }) => {
test('select color in color picker', async ({ gotoPanelEditPage }) => {
const panelEdit = await gotoPanelEditPage({ dashboard: { uid: 'mxb-Jv4Vk' }, id: '3' });
const clockOptions = panelEdit.getCustomOptions('Clock');
const backgroundColor = clockOptions.getColorPicker('Background color');
const backgroundColor = clockOptions.getColorPicker('Background Color');

await backgroundColor.selectOption('#73bf69');
await expect(backgroundColor).toHaveColor('#73bf69');
Expand Down
Loading