Skip to content

OpenProject is the leading open source project management software for product, project and portfolio management. A powerful Jira alternative with agile planning, issue tracking, roadmaps, Gantt charts, time tracking, collaboration features, and more. Available on premises or in the cloud. ⭐ Star us on GitHub

Fix auth spec

Oliver Günther07861d827608
diff --git a/modules/bim/spec/features/bcf/api_authorization_spec.rb b/modules/bim/spec/features/bcf/api_authorization_spec.rb
index 735022ec53f..a0cba3729c0 100644
--- a/modules/bim/spec/features/bcf/api_authorization_spec.rb
+++ b/modules/bim/spec/features/bcf/api_authorization_spec.rb
@@ -28,7 +28,10 @@
require "spec_helper"
-RSpec.describe "authorization for BCF api", :js, with_config: { edition: "bim" } do
+RSpec.describe "authorization for BCF api",
+ :js,
+ :with_cuprite,
+ with_config: { edition: "bim" } do
let!(:user) { create(:admin) }
let(:client_secret) { app.plaintext_secret }
let(:scope) { "bcf_v2_1" }
@@ -40,6 +43,7 @@ RSpec.describe "authorization for BCF api", :js, with_config: { edition: "bim" }
before do
login_with user.login, "adminADMIN!"
+ wait_for_network_idle
visit oauth_applications_path
end
@@ -126,7 +130,8 @@ RSpec.describe "authorization for BCF api", :js, with_config: { edition: "bim" }
expect(page)
.to have_content(JSON.dump({ project_id: project.id, name: project.name }))
- logout
+ visit signout_path
+ wait_for_network_idle
# A basic auth alert is displayed asking to enter name and password Register
# some basic auth credentials