Skip to content

Commit 8faaee3

Browse files
RUBY-2849 Fix GitHub Actions (#2386)
* RUBY-2849 Fix GitHub Actions * Specify database for examples * Fix actions * 2849 * 2849 * 2849
1 parent b0621bb commit 8faaee3

File tree

4 files changed

+23
-4
lines changed

4 files changed

+23
-4
lines changed

.github/workflows/test.yml

Lines changed: 15 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -62,9 +62,23 @@ jobs:
6262
bundler: 2
6363
- name: bundle
6464
run: bundle install --jobs 4 --retry 3
65+
- name: prepare test suite
66+
run: bundle exec rake spec:prepare
67+
env:
68+
MONGODB_URI: ${{ steps.start-mongodb.outputs.cluster-uri }}
69+
- name: prepare replica set
70+
run: ruby -Ilib -I.evergreen/lib -rbundler/setup -rserver_setup -e ServerSetup.new.setup_tags
71+
if: ${{ matrix.topology == 'replica_set' }}
72+
env:
73+
MONGODB_URI: ${{ steps.start-mongodb.outputs.cluster-uri }}
74+
- name: wait for sessions
75+
run: bundle exec rake spec:wait_for_sessions
76+
if: ${{ matrix.topology == 'sharded_cluster' && matrix.mongodb == '3.6' }}
77+
env:
78+
MONGODB_URI: ${{ steps.start-mongodb.outputs.cluster-uri }}
6579
- name: test
6680
timeout-minutes: 60
67-
continue-on-error: true
81+
continue-on-error: false
6882
run: bundle exec rake spec:ci
6983
env:
7084
MONGODB_URI: ${{ steps.start-mongodb.outputs.cluster-uri }}

spec/integration/versioned_api_examples_spec.rb

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,9 +9,10 @@
99
# the tests to simple configurations
1010
require_no_auth
1111
require_no_tls
12+
min_server_version("5.0")
1213

1314
let(:uri_string) do
14-
"mongodb://#{SpecConfig.instance.addresses.join(',')}"
15+
"mongodb://#{SpecConfig.instance.addresses.join(',')}/versioned-api-examples"
1516
end
1617

1718
it 'Versioned API example 1' do

spec/shared

spec/support/spec_config.rb

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -296,7 +296,11 @@ def client_cert_path
296296
end
297297

298298
def local_client_pem_path
299-
"#{ssl_certs_dir}/client.pem"
299+
if (algo = ENV['OCSP_ALGORITHM'])&.empty?
300+
"#{ssl_certs_dir}/client.pem"
301+
else
302+
Pathname.new("#{spec_root}/support/ocsp/#{algo}/server.pem")
303+
end
300304
end
301305

302306
def client_pem_path

0 commit comments

Comments
 (0)