@@ -31,25 +31,27 @@ func TestNewRunner(t *testing.T) {
|
||||
net := test.GetNetwork(t)
|
||||
|
||||
var wg sync.WaitGroup
|
||||
|
||||
wg.Add(1)
|
||||
go func() {
|
||||
a := test.CreateAWSContainer(t, cfg, net)
|
||||
test.SetQueueClient(t, t.Context(), cfg, a.ExternalEndpoint)
|
||||
cfg.QueueURL = test.CreateQueue(t, t.Context(), cfg, "queueName")
|
||||
cfg.SetSQSEndpoint(a.ExternalEndpoint)
|
||||
test.CreateDB(t, cfg, net, &test.CreateDatabaseConfig{
|
||||
NoMigrations: true,
|
||||
})
|
||||
|
||||
cfg.ControllerFunc = func() Controller[interface{}] {
|
||||
return runnermock.NewMockController[interface{}](t)
|
||||
}
|
||||
wg.Done()
|
||||
}()
|
||||
|
||||
a := test.CreateAWSContainer(t, cfg, net)
|
||||
test.SetQueueClient(t, t.Context(), cfg, a.ExternalEndpoint)
|
||||
|
||||
cfg.QueueURL = test.CreateQueue(t, t.Context(), cfg, "queueName")
|
||||
cfg.SetSQSEndpoint(a.ExternalEndpoint)
|
||||
|
||||
wg.Wait()
|
||||
|
||||
test.CreateDB(t, cfg, net, &test.CreateDatabaseConfig{
|
||||
NoMigrations: true,
|
||||
})
|
||||
|
||||
cfg.ControllerFunc = func() Controller[interface{}] {
|
||||
return runnermock.NewMockController[interface{}](t)
|
||||
}
|
||||
|
||||
srvPtr, err := New(t.Context(), cfg)
|
||||
require.NoError(t, err)
|
||||
assert.NotNil(t, srvPtr)
|
||||
|
||||
Reference in New Issue
Block a user