Replace remaining calls to testing.Short where possible. (#110765)

* Replace remaining calls to testing.Short where possible.
* Update style guide.
* Revert change in TestAlertmanager_ExtraDedupStage, as it doesn't work.
* Make TestAlertRulePostExport into integration test.
This commit is contained in:
Peter Štibraný
2025-09-09 08:16:12 +00:00
committed by GitHub
parent ffcc0e8de0
commit c32650e9d8
16 changed files with 76 additions and 88 deletions
+7 -4
View File
@@ -12,14 +12,16 @@ import (
"testing"
"time"
"github.com/grafana/grafana/pkg/configprovider"
"github.com/grafana/grafana/pkg/services/featuremgmt"
"github.com/grafana/grafana/pkg/services/sqlstore/sqlutil"
"github.com/prometheus/client_golang/prometheus"
"github.com/stretchr/testify/assert"
"github.com/stretchr/testify/require"
"gopkg.in/ini.v1"
"github.com/grafana/grafana/pkg/configprovider"
"github.com/grafana/grafana/pkg/services/featuremgmt"
"github.com/grafana/grafana/pkg/services/sqlstore/sqlutil"
"github.com/grafana/grafana/pkg/util/testutil"
"github.com/grafana/dskit/kv"
"github.com/grafana/grafana/pkg/api"
@@ -570,8 +572,9 @@ func CreateGrafDir(t *testing.T, opts GrafanaOpts) (string, string) {
func SQLiteIntegrationTest(t *testing.T) {
t.Helper()
testutil.SkipIntegrationTestInShortMode(t)
if testing.Short() || !db.IsTestDbSQLite() {
if !db.IsTestDbSQLite() {
t.Skip("skipping integration test")
}
}