Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add latest stable version of JRuby to Travis CI build matrix #288

Merged
merged 3 commits into from Dec 1, 2016
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
7 changes: 7 additions & 0 deletions .travis.yml
Expand Up @@ -9,12 +9,16 @@ rvm:
- 2.1
- 2.2
- 2.3
- jruby
gemfile:
- Gemfile
env:
- MOCHA_OPTIONS=debug
matrix:
include:
- rvm: jruby
gemfile: gemfiles/Gemfile.minitest.latest
env: MOCHA_OPTIONS=debug MOCHA_RUN_INTEGRATION_TESTS=minitest
- rvm: 2.3
gemfile: gemfiles/Gemfile.minitest.latest
env: MOCHA_OPTIONS=debug MOCHA_RUN_INTEGRATION_TESTS=minitest
Expand Down Expand Up @@ -75,6 +79,9 @@ matrix:
- rvm: 1.8.7
gemfile: gemfiles/Gemfile.minitest.1.3.0
env: MOCHA_OPTIONS=debug MOCHA_RUN_INTEGRATION_TESTS=minitest
- rvm: jruby
gemfile: gemfiles/Gemfile.test-unit.latest
env: MOCHA_OPTIONS=debug MOCHA_RUN_INTEGRATION_TESTS=test-unit
- rvm: 2.3
gemfile: gemfiles/Gemfile.test-unit.latest
env: MOCHA_OPTIONS=debug MOCHA_RUN_INTEGRATION_TESTS=test-unit
Expand Down
10 changes: 6 additions & 4 deletions test/execution_point.rb
Expand Up @@ -10,14 +10,16 @@ def initialize(backtrace)
@backtrace = backtrace
end

def first_relevant_line_of_backtrace
@backtrace && (@backtrace.reject { |l| /\Aorg\/jruby\//.match(l) }.first || 'unknown:0')
end

def file_name
return "unknown" unless @backtrace && @backtrace.first
/\A(.*?):\d+/.match(@backtrace.first)[1]
/\A(.*?):\d+/.match(first_relevant_line_of_backtrace)[1]
end

def line_number
return "unknown" unless @backtrace && @backtrace.first
Integer(/\A.*?:(\d+)/.match(@backtrace.first)[1])
Integer(/\A.*?:(\d+)/.match(first_relevant_line_of_backtrace)[1])
end

def ==(other)
Expand Down