mirror of
https://github.com/zitadel/zitadel.git
synced 2025-04-07 12:54:32 +00:00
skip mfa
This commit is contained in:
parent
dde0266192
commit
5fd90efab1
@ -17,6 +17,7 @@ import (
|
||||
func execute(ctx context.Context, cmd *command.Commands, cfg E2EConfig, users []userData) error {
|
||||
|
||||
ctx = authz.WithInstanceID(ctx, cfg.InstanceID)
|
||||
ctx = authz.WithRequestedDomain(ctx, "localhost")
|
||||
|
||||
orgOwner := newHuman(users[0])
|
||||
|
||||
@ -41,6 +42,11 @@ func execute(ctx context.Context, cmd *command.Commands, cfg E2EConfig, users []
|
||||
return err
|
||||
}
|
||||
|
||||
// skip mfa
|
||||
if err = cmd.HumanSkipMFAInit(ctx, orgOwnerID, org.ResourceOwner); err != nil {
|
||||
return err
|
||||
}
|
||||
|
||||
sa, err := cmd.AddMachine(ctx, org.ResourceOwner, &domain.Machine{
|
||||
Username: "e2e",
|
||||
Name: "e2e",
|
||||
@ -91,6 +97,11 @@ func execute(ctx context.Context, cmd *command.Commands, cfg E2EConfig, users []
|
||||
return err
|
||||
}
|
||||
|
||||
// skip mfa
|
||||
if err = cmd.HumanSkipMFAInit(ctx, orgOwnerID, org.ResourceOwner); err != nil {
|
||||
return err
|
||||
}
|
||||
|
||||
if user.role != "" {
|
||||
if _, err = cmd.AddOrgMember(ctx, org.ResourceOwner, createdHuman.ID, user.role); err != nil {
|
||||
return err
|
||||
|
Loading…
x
Reference in New Issue
Block a user