diff options
author | 2021-09-01 11:45:01 +0200 | |
---|---|---|
committer | 2021-09-01 11:45:01 +0200 | |
commit | 684bd56528c5ffa37af8340b8b141fe390dd05a4 (patch) | |
tree | 4a78d70c2ca7f15e47f8a2e6bc51d62c99b0f52d /testrig | |
parent | Merge branch 'struct_validation' of github.com:superseriousbusiness/gotosocia... (diff) | |
download | gotosocial-684bd56528c5ffa37af8340b8b141fe390dd05a4.tar.xz |
move oauth models into gtsmodel
Diffstat (limited to 'testrig')
-rw-r--r-- | testrig/db.go | 5 | ||||
-rw-r--r-- | testrig/testmodels.go | 9 |
2 files changed, 6 insertions, 8 deletions
diff --git a/testrig/db.go b/testrig/db.go index 52a1af6e9..7cb4f7645 100644 --- a/testrig/db.go +++ b/testrig/db.go @@ -26,7 +26,6 @@ import ( "github.com/superseriousbusiness/gotosocial/internal/db" "github.com/superseriousbusiness/gotosocial/internal/db/bundb" "github.com/superseriousbusiness/gotosocial/internal/gtsmodel" - "github.com/superseriousbusiness/gotosocial/internal/oauth" ) var testModels []interface{} = []interface{}{ @@ -51,8 +50,8 @@ var testModels []interface{} = []interface{}{ >smodel.Instance{}, >smodel.Notification{}, >smodel.RouterSession{}, - &oauth.Token{}, - &oauth.Client{}, + >smodel.Token{}, + >smodel.Client{}, } // NewTestDB returns a new initialized, empty database for testing. diff --git a/testrig/testmodels.go b/testrig/testmodels.go index a7148ae17..388c0cadd 100644 --- a/testrig/testmodels.go +++ b/testrig/testmodels.go @@ -38,12 +38,11 @@ import ( "github.com/go-fed/activity/streams/vocab" "github.com/superseriousbusiness/gotosocial/internal/ap" "github.com/superseriousbusiness/gotosocial/internal/gtsmodel" - "github.com/superseriousbusiness/gotosocial/internal/oauth" ) // NewTestTokens returns a map of tokens keyed according to which account the token belongs to. -func NewTestTokens() map[string]*oauth.Token { - tokens := map[string]*oauth.Token{ +func NewTestTokens() map[string]*gtsmodel.Token { + tokens := map[string]*gtsmodel.Token{ "local_account_1": { ID: "01F8MGTQW4DKTDF8SW5CT9HYGA", ClientID: "01F8MGV8AC3NGSJW0FE8W1BV70", @@ -69,8 +68,8 @@ func NewTestTokens() map[string]*oauth.Token { } // NewTestClients returns a map of Clients keyed according to which account they are used by. -func NewTestClients() map[string]*oauth.Client { - clients := map[string]*oauth.Client{ +func NewTestClients() map[string]*gtsmodel.Client { + clients := map[string]*gtsmodel.Client{ "admin_account": { ID: "01F8MGWSJCND9BWBD4WGJXBM93", Secret: "dda8e835-2c9c-4bd2-9b8b-77c2e26d7a7a", |