test: fix most integration tests (live)

This commit is contained in:
James Houlahan
2020-04-09 10:24:58 +02:00
parent bafd4e714e
commit fec5f2d3c3
18 changed files with 124 additions and 104 deletions

View File

@ -35,17 +35,20 @@ type server interface {
// TestContext manages a bridge test (mocked API, bridge instance, IMAP/SMTP servers, setup steps).
type TestContext struct {
// Base setup for the whole bridge (core & imap & smtp).
t *bddT
cfg *fakeConfig
listener listener.Listener
pmapiController PMAPIController // pmapiController is used to create pmapi clients (either real or fake) and control server state.
testAccounts *accounts.TestAccounts
t *bddT
cfg *fakeConfig
listener listener.Listener
testAccounts *accounts.TestAccounts
// pmapiController is used to control real or fake pmapi clients.
// The clients are created by the clientManager.
pmapiController PMAPIController
clientManager *pmapi.ClientManager
// Bridge core related variables.
bridge *bridge.Bridge
bridgeLastError error
credStore bridge.CredentialsStorer
clientManager *pmapi.ClientManager
// IMAP related variables.
imapAddr string