Update scenes to v5.23.1 (#95951)

* Update scenes to v5.23.1

* Fix e2e tests

* Fix unit tests

---------

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
Co-authored-by: Bogdan Matei <bogdan.matei@grafana.com>
This commit is contained in:
renovate[bot]
2024-11-06 19:20:27 +02:00
committed by GitHub
co-authored by Bogdan Matei
parent fbbb4463f8
commit 70c21a2e4d
4 changed files with 43 additions and 16 deletions
@@ -9,6 +9,9 @@ describe('Dashboard templating', () => {
// Open dashboard global variables and interpolation
e2e.flows.openDashboard({ uid: 'HYaGDGIMk' });
const timeZone = Intl.DateTimeFormat().resolvedOptions().timeZone;
const example = `Example: from=now-6h&to=now&timezone=${encodeURIComponent(timeZone)}`;
const items: string[] = [];
const expectedItems: string[] = [
'__dashboard = Templating - Global variables and interpolation',
@@ -36,7 +39,7 @@ describe('Dashboard templating', () => {
`Server:text = All`,
`Server:queryparam = var-Server=$__all`,
`1 < 2`,
`Example: from=now-6h&to=now`,
example,
];
cy.get('.markdown-html li')
@@ -51,10 +54,10 @@ describe('Dashboard templating', () => {
});
// Check link interpolation is working correctly
cy.contains('a', 'Example: from=now-6h&to=now').should(
cy.contains('a', example).should(
'have.attr',
'href',
'https://example.com/?from=now-6h&to=now'
`https://example.com/?from=now-6h&to=now&timezone=${encodeURIComponent(timeZone)}`
);
});
});