Skip tests in short mode

This commit is contained in:
Till Faelligen 2022-11-30 11:16:55 +01:00
parent ed497aa8b2
commit eea4832a32
No known key found for this signature in database
GPG key ID: ACCDC9606D472758
2 changed files with 6 additions and 0 deletions

View file

@ -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,

View file

@ -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,