From c68263b1fd5dc4e5818394ec77368bf11ca2767e Mon Sep 17 00:00:00 2001 From: Chong Yidong Date: Sat, 14 Aug 2010 20:04:53 -0400 Subject: [PATCH] Give Ruby compilation rule a lower priority than Gnu (Bug#6778). * progmodes/compile.el (compilation-error-regexp-alist-alist): Give the Ruby rule a lower priority than Gnu (Bug#6778). * etc/compilation.txt: Make Cucumber test less verbose. --- etc/compilation.txt | 44 ++++++++++++++------------------------- lisp/ChangeLog | 5 +++++ lisp/progmodes/compile.el | 8 +++---- 3 files changed, 25 insertions(+), 32 deletions(-) diff --git a/etc/compilation.txt b/etc/compilation.txt index 2041b7f0acc..9cf39c90f9f 100644 --- a/etc/compilation.txt +++ b/etc/compilation.txt @@ -102,42 +102,30 @@ Feature: This is an example for backtrace. Scenario: undefined step # features/cucumber.feature:3 Given this is undefined # features/cucumber.feature:4 - Scenario: assertion false (Test::Unit) # features/cucumber.feature:6 - Given this will generate 'assert false' # features/step_definitions/default_steps.rb:1 + Scenario: assertion false (Test::Unit) # foo/bar.feature:6 + Given this will generate 'assert false' # foo/bar.rb:1 is not true. (Test::Unit::AssertionFailedError) - /home/gusev/.rvm/rubies/ruby-1.8.7-p249/lib/ruby/1.8/test/unit/assertions.rb:48:in `assert_block' - /home/gusev/.rvm/rubies/ruby-1.8.7-p249/lib/ruby/1.8/test/unit/assertions.rb:500:in `_wrap_assertion' - /home/gusev/.rvm/rubies/ruby-1.8.7-p249/lib/ruby/1.8/test/unit/assertions.rb:46:in `assert_block' - /home/gusev/.rvm/rubies/ruby-1.8.7-p249/lib/ruby/1.8/test/unit/assertions.rb:63:in `assert' - /home/gusev/.rvm/rubies/ruby-1.8.7-p249/lib/ruby/1.8/test/unit/assertions.rb:495:in `_wrap_assertion' - /home/gusev/.rvm/rubies/ruby-1.8.7-p249/lib/ruby/1.8/test/unit/assertions.rb:61:in `assert' - ./features/step_definitions/default_steps.rb:2:in `/^this will generate 'assert false'$/' + /home/gusev/.rvm/foo/bar.rb:48:in `assert_block' + /home/gusev/.rvm/foo/bar.rb:500:in `_wrap_assertion' features/cucumber.feature:7:in `Given this will generate 'assert false'' - Scenario: assertion false (RSpec) # features/cucumber.feature:9 - Given this will generate 'should be_true' # features/step_definitions/default_steps.rb:5 + Scenario: assertion false (RSpec) # foo/bar.feature:9 + Given this will generate 'should be_true' # foo/bar.rb:5 expected true to be false (Spec::Expectations::ExpectationNotMetError) - ./features/step_definitions/default_steps.rb:6:in `/^this will generate 'should be_true'$/' - features/cucumber.feature:10:in `Given this will generate 'should be_true'' + ./foo/bar/baz.rb:6:in `/^this will generate 'should be_true'$/' + foo/bar.feature:10:in `Given this will generate 'should be_true'' - Scenario: backtrace in step definition # features/cucumber.feature:12 - Given this will generate backtrace # features/step_definitions/default_steps.rb:9 + Scenario: backtrace in step definition # foo/bar.feature:12 + Given this will generate backtrace # foo/sbar.rb:9 (RuntimeError) - ./features/step_definitions/default_steps.rb:10:in `/^this will generate backtrace$/' - features/cucumber.feature:13:in `Given this will generate backtrace' - - Scenario: deeep backtrace in step definition # features/cucumber.feature:15 - Given this will generate deep backtrace # features/step_definitions/default_steps.rb:13 - (RuntimeError) - ./features/step_definitions/default_steps.rb:18:in `deep' - ./features/step_definitions/default_steps.rb:14:in `/^this will generate deep backtrace$/' - features/cucumber.feature:16:in `Given this will generate deep backtrace' + ./foo/bar.rb:10:in `/^this will generate backtrace$/' + foo/bar.feature:13:in `Given this will generate backtrace' Failing Scenarios: -cucumber features/cucumber.feature:6 # Scenario: assertion false (Test::Unit) -cucumber features/cucumber.feature:9 # Scenario: assertion false (RSpec) -cucumber features/cucumber.feature:12 # Scenario: backtrace in step definition -cucumber features/cucumber.feature:15 # Scenario: deeep backtrace in step definition +cucumber foo/cucumber.feature:6 # Scenario: assertion false (Test::Unit) +cucumber foo/cucumber.feature:9 # Scenario: assertion false (RSpec) +cucumber foo/cucumber.feature:12 # Scenario: backtrace in step definition +cucumber foo/cucumber.feature:15 # Scenario: deeep backtrace in step definition 5 scenarios (4 failed, 1 undefined) 5 steps (4 failed, 1 undefined) diff --git a/lisp/ChangeLog b/lisp/ChangeLog index e2f68ba7677..bc1bcac7191 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,3 +1,8 @@ +2010-08-15 Chong Yidong + + * progmodes/compile.el (compilation-error-regexp-alist-alist): + Give the Ruby rule a lower priority than Gnu (Bug#6778). + 2010-08-14 Štěpán Němec (tiny change) * font-lock.el (lisp-font-lock-keywords-2): Add diff --git a/lisp/progmodes/compile.el b/lisp/progmodes/compile.el index c92d6a9f052..a909006e0c0 100644 --- a/lisp/progmodes/compile.el +++ b/lisp/progmodes/compile.el @@ -227,6 +227,10 @@ of[ \t]+\"?\\([a-zA-Z]?:?[^\":\n]+\\)\"?:" 3 2 nil (1)) "^[-[:alnum:]_/ ]+: \\(?:\\(?:[sS]evere\\|[eE]rror\\|[wW]arnin\\(g\\)\\|[iI]nf\\(o\\)\\)[0-9 ]*: \\)?\ \\([^,\" \n\t]+\\)\\(?:, line\\|:\\) \\([0-9]+\\):" 3 4 nil (1 . 2)) + (ruby + "^[\t ]*\\(?:from \\)?\ +\\([^\(\n][^[:space:]\n]*\\):\\([1-9][0-9]*\\)\\(:in `.*'\\)?.*$" 1 2) + (java "^\\(?:[ \t]+at \\|==[0-9]+== +\\(?:at\\|b\\(y\\)\\)\\).+(\\([^()\n]+\\):\\([0-9]+\\))$" 2 3 nil (1)) @@ -329,10 +333,6 @@ during global destruction\\.$\\)" 1 2) "\\(?:Parse\\|Fatal\\) error: \\(.*\\) in \\(.*\\) on line \\([0-9]+\\)" 2 3 nil nil) - (ruby - "^[\t ]*\\(?:from \\)?\ -\\([^\(\n][^[:space:]\n]*\\):\\([1-9][0-9]*\\)\\(:in `.*'\\)?.*$" 1 2) - (ruby-Test::Unit "[\t ]*\\[\\([^\(].*\\):\\([1-9][0-9]*\\)\\(\\]\\)?:$" 1 2) -- 2.39.2