[v9.4.x] Expressions: Fixes the issue showing expressions editor (#62622)

Expressions: Fixes the issue showing expressions editor (#62510)

* Use suggested value for uid

* update the snapshot

* use __expr__

* replace all -100 with __expr__

* update snapshot

* more changes

* revert redundant change

* Use expr.DatasourceUID where it's possible

* generate files

(cherry picked from commit 91221bc436)

Co-authored-by: ismail simsek <ismailsimsek09@gmail.com>
This commit is contained in:
Grot (@grafanabot)
2023-01-31 18:10:13 +00:00
committed by GitHub
co-authored by ismail simsek
parent bd9707e8f3
commit 4bdfc2d926
54 changed files with 254 additions and 236 deletions
@@ -8,6 +8,7 @@ import (
"testing"
"time"
"github.com/grafana/grafana/pkg/expr"
"github.com/stretchr/testify/assert"
"github.com/stretchr/testify/require"
@@ -737,7 +738,7 @@ func insertTestRule(t *testing.T, sqlStore db.DB, foderOrgID int64, folderUID st
Data: []alertQuery{
{
RefID: "A",
DatasourceUID: "-100",
DatasourceUID: expr.DatasourceUID,
Model: json.RawMessage(`{
"type": "math",
"expression": "2 + 3 > 1"