diff options
| author | Can Eldem <celdem@gitlab.com> | 2020-07-23 11:01:47 +0000 |
|---|---|---|
| committer | Can Eldem <celdem@gitlab.com> | 2020-07-23 11:01:47 +0000 |
| commit | 8ee0824204c0e97d97ad6d38778cd9e7e9da6813 (patch) | |
| tree | d851d65d729ecdffd018c79c6f5d887a1e506bce /spec/integration/python/pipenv_spec.rb | |
| parent | ca675527b53c2a8316c962ee1a17bc1ee1c0c156 (diff) | |
| parent | dfa59682cfe6cc3726c321236b1e0db5e965e722 (diff) | |
Merge branch 'offline-tests' into 'master'v3.19.2
Combine default/custom x509 certificates in TLS validation
See merge request gitlab-org/security-products/license-management!194
Diffstat (limited to 'spec/integration/python/pipenv_spec.rb')
| -rw-r--r-- | spec/integration/python/pipenv_spec.rb | 10 |
1 files changed, 6 insertions, 4 deletions
diff --git a/spec/integration/python/pipenv_spec.rb b/spec/integration/python/pipenv_spec.rb index b95f1fa..5cc9128 100644 --- a/spec/integration/python/pipenv_spec.rb +++ b/spec/integration/python/pipenv_spec.rb @@ -202,18 +202,20 @@ RSpec.describe "pipenv" do end end - context "when connecting to a private package repository with self signed certificate", environment: 'offline' do - let(:index_url) { "https://#{private_pypi_host}/simple" } - let(:bundle) { fixture_file_content('python/pypi.crt') } + context "when connecting to a private package repository with self signed certificate" do + let(:index_url) { "https://pypi.test/simple" } before do + add_host('pypi.test', '127.0.0.1') + start_proxy_server + runner.add_file('Pipfile', fixture_file_content('python/airgap-Pipfile.erb', index_url: index_url)) runner.add_file('Pipfile.lock', fixture_file_content('python/airgap-Pipfile.lock.erb', index_url: index_url)) end it 'downloads the packages and trusts the certificate' do report = runner.scan(env: { - 'ADDITIONAL_CA_CERT_BUNDLE' => bundle, + 'ADDITIONAL_CA_CERT_BUNDLE' => x509_certificate('wildcard.test').read, 'PIP_INDEX_URL' => index_url }) |
