From dd0dcad8c40d0b2e879c61548bf1a8ec622cc801 Mon Sep 17 00:00:00 2001 From: Ryan Richard Date: Wed, 5 Mar 2025 12:13:45 -0800 Subject: [PATCH] slow down filling out the Okta login screen for Chrome v134 --- test/testlib/browsertest/browsertest.go | 11 +++++++++-- 1 file changed, 9 insertions(+), 2 deletions(-) diff --git a/test/testlib/browsertest/browsertest.go b/test/testlib/browsertest/browsertest.go index 0064e12ec..955b7ef61 100644 --- a/test/testlib/browsertest/browsertest.go +++ b/test/testlib/browsertest/browsertest.go @@ -1,4 +1,4 @@ -// Copyright 2020-2024 the Pinniped contributors. All Rights Reserved. +// Copyright 2020-2025 the Pinniped contributors. All Rights Reserved. // SPDX-License-Identifier: Apache-2.0 // Package browsertest provides integration test helpers for our browser-based tests. @@ -391,11 +391,18 @@ func LoginToUpstreamOIDC(t *testing.T, b *Browser, upstream testlib.TestOIDCUpst // Fill in the username and password and click "submit". t.Logf("logging into %s", cfg.Name) + b.SendKeysToFirstMatch(t, cfg.UsernameSelector, upstream.Username) + + // The Okta login page has a lot of Javascript on it. Give it a second to catch up after typing the + // username. Hoping that this might help with the test flake that started in Chrome v134 where the + // username and password fields are not filled in correctly. + time.Sleep(1 * time.Second) + b.SendKeysToFirstMatch(t, cfg.PasswordSelector, upstream.Password) // The Okta login page has a lot of Javascript on it. Give it a second to catch up after typing the - // username and password. Hoping that this might help with the test flake where the Okta login page + // password. Hoping that this might help with the test flake where the Okta login page // never continues to the next page after trying to click the login button below. time.Sleep(1 * time.Second)