mirror of
https://github.com/grafana/grafana.git
synced 2025-02-25 18:55:37 -06:00
@grafana/e2e: flaky chart data workaround (#27687)
Don't expect initial chart data when creating a panel that hasn't yet populated its query editor
This commit is contained in:
parent
98f7a2ace0
commit
abb015bad6
@ -127,15 +127,20 @@ export const configurePanel = (config: PartialAddPanelConfig | PartialEditPanelC
|
||||
// @todo instead wait for '@pluginModule'
|
||||
e2e().wait(2000);
|
||||
|
||||
if (!isExplore) {
|
||||
// There is no usable data when the query is empty,
|
||||
// and Cypress had an issue with some plugins where the request wasn't noticed, despite occuring in manual tests
|
||||
if (isEdit) {
|
||||
// Avoid cache flakiness (where @chartData isn't requested)
|
||||
// @todo this may not be necessary anymore
|
||||
e2e()
|
||||
.get('.refresh-picker-buttons .btn')
|
||||
.first()
|
||||
.click({ force: true });
|
||||
|
||||
e2e().wait('@chartData');
|
||||
}
|
||||
|
||||
if (!isExplore) {
|
||||
// `panelTitle` is needed to edit the panel, and unlikely to have its value changed at that point
|
||||
const changeTitle = panelTitle && !isEdit;
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user