First db migration (#297)

* store first db schema

* md linting *screams*
This commit is contained in:
tobi
2021-11-13 17:30:01 +01:00
committed by GitHub
parent 09ef9e639e
commit aee1932bd4
28 changed files with 1114 additions and 39 deletions

View File

@ -109,21 +109,6 @@ func (suite *AuthTestSuite) SetupTest() {
}
suite.db = db
models := []interface{}{
&gtsmodel.Client{},
&gtsmodel.Token{},
&gtsmodel.User{},
&gtsmodel.Account{},
&gtsmodel.Application{},
}
for _, m := range models {
if err := suite.db.CreateTable(context.Background(), m); err != nil {
logrus.Panicf("db connection error: %s", err)
}
}
suite.oauthServer = oauth.New(context.Background(), suite.db)
if err := suite.db.Put(context.Background(), suite.testAccount); err != nil {