mirror of
https://github.com/zitadel/zitadel.git
synced 2024-12-15 12:27:59 +00:00
38 lines
684 B
Go
38 lines
684 B
Go
|
//go:build integration
|
||
|
|
||
|
package quotas_enabled_test
|
||
|
|
||
|
import (
|
||
|
"context"
|
||
|
"os"
|
||
|
"testing"
|
||
|
"time"
|
||
|
|
||
|
"github.com/zitadel/zitadel/internal/integration"
|
||
|
)
|
||
|
|
||
|
var (
|
||
|
CTX context.Context
|
||
|
SystemCTX context.Context
|
||
|
IAMOwnerCTX context.Context
|
||
|
Tester *integration.Tester
|
||
|
)
|
||
|
|
||
|
func TestMain(m *testing.M) {
|
||
|
os.Exit(func() int {
|
||
|
ctx, _, cancel := integration.Contexts(5 * time.Minute)
|
||
|
defer cancel()
|
||
|
CTX = ctx
|
||
|
|
||
|
Tester = integration.NewTester(ctx, `
|
||
|
Quotas:
|
||
|
Access:
|
||
|
Enabled: true
|
||
|
`)
|
||
|
defer Tester.Done()
|
||
|
SystemCTX = Tester.WithAuthorization(ctx, integration.SystemUser)
|
||
|
IAMOwnerCTX = Tester.WithAuthorization(ctx, integration.IAMOwner)
|
||
|
return m.Run()
|
||
|
}())
|
||
|
}
|