From eea4832a32441a28ce180b7bb2610811018e4334 Mon Sep 17 00:00:00 2001 From: Till Faelligen <2353100+S7evinK@users.noreply.github.com> Date: Wed, 30 Nov 2022 11:16:55 +0100 Subject: [PATCH] Skip tests in short mode --- test/db.go | 3 +++ test/testrig/base.go | 3 +++ 2 files changed, 6 insertions(+) diff --git a/test/db.go b/test/db.go index 17f637e18..3a817fd08 100644 --- a/test/db.go +++ b/test/db.go @@ -169,6 +169,9 @@ func PrepareDBConnectionString(t *testing.T, dbType DBType) (connStr string, clo // Creates subtests with each known DBType func WithAllDatabases(t *testing.T, testFn func(t *testing.T, db DBType)) { + if testing.Short() { + t.Skip("skipping test in short mode.") + } dbs := map[string]DBType{ "postgres": DBTypePostgres, "sqlite": DBTypeSQLite, diff --git a/test/testrig/base.go b/test/testrig/base.go index 15fb5c370..81025fd3b 100644 --- a/test/testrig/base.go +++ b/test/testrig/base.go @@ -30,6 +30,9 @@ import ( ) func CreateBaseDendrite(t *testing.T, dbType test.DBType) (*base.BaseDendrite, func()) { + if testing.Short() { + t.Skip("skipping test in short mode.") + } var cfg config.Dendrite cfg.Defaults(config.DefaultOpts{ Generate: false,