2022-07-23 23:45:48 +05:30
|
|
|
# frozen_string_literal: true
|
|
|
|
|
|
|
|
require 'spec_helper'
|
|
|
|
|
2023-03-04 22:38:38 +05:30
|
|
|
RSpec.describe 'Zuora content security policy', feature_category: :purchase do
|
2022-07-23 23:45:48 +05:30
|
|
|
let(:user) { create(:user) }
|
|
|
|
let(:project) { create(:project) }
|
|
|
|
let(:pipeline) { create(:ci_pipeline, project: project) }
|
|
|
|
|
|
|
|
before do
|
|
|
|
project.add_developer(user)
|
|
|
|
sign_in(user)
|
|
|
|
end
|
|
|
|
|
|
|
|
it 'has proper Content Security Policy headers' do
|
|
|
|
visit pipeline_path(pipeline)
|
|
|
|
|
|
|
|
expect(response_headers['Content-Security-Policy']).to include('https://*.zuora.com')
|
|
|
|
end
|
|
|
|
end
|