diff --git a/modules/openid_connect/spec/requests/openid_connect_spec.rb b/modules/openid_connect/spec/requests/openid_connect_spec.rb index 3d9d262d5d68..7eed51cc70f3 100644 --- a/modules/openid_connect/spec/requests/openid_connect_spec.rb +++ b/modules/openid_connect/spec/requests/openid_connect_spec.rb @@ -67,10 +67,7 @@ describe "sign-up and login" do let(:limit_self_registration) { false } - - before do - create(:oidc_provider, slug: "keycloak", limit_self_registration:) - end + let!(:provider) { create(:oidc_provider, slug: "keycloak", limit_self_registration:) } it "logs in the user" do ## @@ -144,12 +141,7 @@ let(:limit_self_registration) { true } it "does not allow registration" do - ## - # it should redirect to the provider's openid connect authentication endpoint click_on_signin("keycloak") - - ## - # it should redirect back from the provider to the login page redirect_from_provider("keycloak") expect(response).to have_http_status :found @@ -158,7 +150,7 @@ user = User.find_by(mail: user_info[:email]) expect(user).to be_registered - expect(user).not_to be active + expect(user).not_to be_active end end @@ -200,9 +192,8 @@ end it "maps to the login" do - skip "Mapping is not supported yet" - click_on_signin - redirect_from_provider + click_on_signin("keycloak") + redirect_from_provider("keycloak") user = User.find_by(login: "a.truly.random.value") expect(user).to be_present