Skip to content

Commit 9892a68

Browse files
MONGOID-5549 Fix app spec failures on JRuby (#5564)
1 parent 97a70b8 commit 9892a68

File tree

2 files changed

+18
-14
lines changed

2 files changed

+18
-14
lines changed

.evergreen/config.yml

Lines changed: 12 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -763,16 +763,15 @@ buildvariants:
763763
tasks:
764764
- name: "test"
765765

766-
# https://jira.mongodb.org/browse/MONGOID-5549
767-
# - matrix_name: app-tests-jruby
768-
# matrix_spec:
769-
# jruby: ["jruby-9.3"]
770-
# driver: ["current"]
771-
# mongodb-version: '5.0'
772-
# topology: standalone
773-
# app-tests: yes
774-
# rails: ['6.0']
775-
# os: ubuntu-18.04
776-
# display_name: "app tests ${driver}, ${jruby}"
777-
# tasks:
778-
# - name: "test"
766+
- matrix_name: app-tests-jruby
767+
matrix_spec:
768+
jruby: ["jruby-9.3"]
769+
driver: ["current"]
770+
mongodb-version: '5.0'
771+
topology: standalone
772+
app-tests: yes
773+
rails: ['6.0']
774+
os: ubuntu-18.04
775+
display_name: "app tests ${driver}, ${jruby}"
776+
tasks:
777+
- name: "test"

spec/integration/app_spec.rb

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -90,7 +90,12 @@ def start_app(cmd, port, timeout)
9090
end
9191

9292
# Exit should be either success or SIGTERM
93-
[0, 15, 128 + 15].should include(status)
93+
allowed_statuses = [0, 15, 128 + 15]
94+
if RUBY_PLATFORM == 'java'
95+
# Puma on JRuby exits with status 1 when it receives a TERM signal.
96+
allowed_statuses << 1
97+
end
98+
allowed_statuses.should include(status)
9499

95100
rv
96101
end

0 commit comments

Comments
 (0)