forgejo/models/main_test.go

35 lines
823 B
Go
Raw Normal View History

// Copyright 2020 The Gitea Authors. All rights reserved.
// SPDX-License-Identifier: MIT
package models
import (
"testing"
activities_model "forgejo.org/models/activities"
"forgejo.org/models/organization"
repo_model "forgejo.org/models/repo"
"forgejo.org/models/unittest"
user_model "forgejo.org/models/user"
_ "forgejo.org/models/actions"
_ "forgejo.org/models/forgefed"
_ "forgejo.org/models/system"
"github.com/stretchr/testify/require"
)
2017-06-04 14:28:17 -04:00
// TestFixturesAreConsistent assert that test fixtures are consistent
func TestFixturesAreConsistent(t *testing.T) {
require.NoError(t, unittest.PrepareTestDatabase())
unittest.CheckConsistencyFor(t,
&user_model.User{},
&repo_model.Repository{},
&organization.Team{},
&activities_model.Action{})
2017-06-04 14:28:17 -04:00
}
func TestMain(m *testing.M) {
unittest.MainTest(m)
}