Skip to content

Commit 75034ac

Browse files
authored
update acp login (#57)
1 parent 53c35e3 commit 75034ac

File tree

1 file changed

+8
-1
lines changed

1 file changed

+8
-1
lines changed

testing/steps/sso.go

Lines changed: 8 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -144,7 +144,14 @@ func loginACP(ctx context.Context, page playwright.Page, params ssoParams) error
144144
if err := page.GetByRole("button", playwright.PageGetByRoleOptions{
145145
Name: "切换本地用户登录",
146146
}).Click(); err != nil {
147-
return fmt.Errorf("点击切换本地用户登录按钮失败: %v", err)
147+
log.Info("点击切换本地用户登录按钮失败: %v", zap.Error(err))
148+
log.Info("尝试点击 Log in with a local account 按钮...")
149+
if err := page.GetByRole("button", playwright.PageGetByRoleOptions{
150+
Name: "Log in with a local account",
151+
Exact: playwright.Bool(true),
152+
}).Click(); err != nil {
153+
return fmt.Errorf("点击 Log in with a local account 按钮失败: %v", err)
154+
}
148155
}
149156
} else {
150157
log.Info("已是本地用户登录页")

0 commit comments

Comments
 (0)