mirror of
https://github.com/zitadel/zitadel.git
synced 2025-08-11 20:37:30 +00:00
fixup! fixup! feat(idp_table_relational): adding inital idp tables for relational repository
This commit is contained in:
@@ -20,7 +20,6 @@ import (
|
|||||||
|
|
||||||
"github.com/google/uuid"
|
"github.com/google/uuid"
|
||||||
"github.com/sirupsen/logrus"
|
"github.com/sirupsen/logrus"
|
||||||
|
|
||||||
"github.com/zitadel/logging"
|
"github.com/zitadel/logging"
|
||||||
"github.com/zitadel/oidc/v3/pkg/client/rp"
|
"github.com/zitadel/oidc/v3/pkg/client/rp"
|
||||||
httphelper "github.com/zitadel/oidc/v3/pkg/http"
|
httphelper "github.com/zitadel/oidc/v3/pkg/http"
|
||||||
|
@@ -42,6 +42,7 @@ const (
|
|||||||
OIDCMappingFieldPreferredLoginName
|
OIDCMappingFieldPreferredLoginName
|
||||||
OIDCMappingFieldEmail
|
OIDCMappingFieldEmail
|
||||||
// count is for validation purposes
|
// count is for validation purposes
|
||||||
|
//nolint: unused
|
||||||
oidcMappingFieldCount
|
oidcMappingFieldCount
|
||||||
)
|
)
|
||||||
|
|
||||||
|
@@ -5,11 +5,11 @@ import (
|
|||||||
"testing"
|
"testing"
|
||||||
"time"
|
"time"
|
||||||
|
|
||||||
"github.com/muhlemmer/gu"
|
|
||||||
|
|
||||||
"github.com/brianvoe/gofakeit/v6"
|
"github.com/brianvoe/gofakeit/v6"
|
||||||
|
"github.com/muhlemmer/gu"
|
||||||
"github.com/stretchr/testify/assert"
|
"github.com/stretchr/testify/assert"
|
||||||
"github.com/stretchr/testify/require"
|
"github.com/stretchr/testify/require"
|
||||||
|
|
||||||
"github.com/zitadel/zitadel/backend/v3/domain"
|
"github.com/zitadel/zitadel/backend/v3/domain"
|
||||||
"github.com/zitadel/zitadel/backend/v3/storage/database"
|
"github.com/zitadel/zitadel/backend/v3/storage/database"
|
||||||
"github.com/zitadel/zitadel/backend/v3/storage/database/repository"
|
"github.com/zitadel/zitadel/backend/v3/storage/database/repository"
|
||||||
@@ -173,7 +173,7 @@ func TestCreateIDProvider(t *testing.T) {
|
|||||||
State: domain.OrgStateActive.String(),
|
State: domain.OrgStateActive.String(),
|
||||||
}
|
}
|
||||||
organizationRepo := repository.OrganizationRepository(pool)
|
organizationRepo := repository.OrganizationRepository(pool)
|
||||||
err = organizationRepo.Create(t.Context(), &org)
|
err = organizationRepo.Create(ctx, &org)
|
||||||
require.NoError(t, err)
|
require.NoError(t, err)
|
||||||
|
|
||||||
idpRepo := repository.IDProviderRepository(pool)
|
idpRepo := repository.IDProviderRepository(pool)
|
||||||
@@ -941,7 +941,7 @@ func TestListIDProvider(t *testing.T) {
|
|||||||
State: domain.OrgStateActive.String(),
|
State: domain.OrgStateActive.String(),
|
||||||
}
|
}
|
||||||
organizationRepo := repository.OrganizationRepository(pool)
|
organizationRepo := repository.OrganizationRepository(pool)
|
||||||
err = organizationRepo.Create(t.Context(), &org)
|
err = organizationRepo.Create(ctx, &org)
|
||||||
require.NoError(t, err)
|
require.NoError(t, err)
|
||||||
|
|
||||||
// create idp
|
// create idp
|
||||||
@@ -1005,7 +1005,7 @@ func TestListIDProvider(t *testing.T) {
|
|||||||
State: domain.OrgStateActive.String(),
|
State: domain.OrgStateActive.String(),
|
||||||
}
|
}
|
||||||
organizationRepo := repository.OrganizationRepository(pool)
|
organizationRepo := repository.OrganizationRepository(pool)
|
||||||
err = organizationRepo.Create(t.Context(), &org)
|
err = organizationRepo.Create(ctx, &org)
|
||||||
require.NoError(t, err)
|
require.NoError(t, err)
|
||||||
|
|
||||||
// create idp
|
// create idp
|
||||||
@@ -1666,7 +1666,7 @@ func TestListIDProvider(t *testing.T) {
|
|||||||
require.NoError(t, err)
|
require.NoError(t, err)
|
||||||
})
|
})
|
||||||
|
|
||||||
ctx := t.Context()
|
ctx := context.WithoutCancel(t.Context())
|
||||||
|
|
||||||
idps := tt.testFunc(ctx, t)
|
idps := tt.testFunc(ctx, t)
|
||||||
|
|
||||||
|
@@ -2,6 +2,7 @@ package command
|
|||||||
|
|
||||||
import (
|
import (
|
||||||
"context"
|
"context"
|
||||||
|
|
||||||
"github.com/zitadel/logging"
|
"github.com/zitadel/logging"
|
||||||
|
|
||||||
"github.com/zitadel/zitadel/internal/domain"
|
"github.com/zitadel/zitadel/internal/domain"
|
||||||
|
Reference in New Issue
Block a user