diff options
-rw-r--r-- | ChangeLog | 6 | ||||
-rw-r--r-- | test/lib/test/unit.rb | 2 |
2 files changed, 7 insertions, 1 deletions
@@ -1,3 +1,9 @@ +Sun May 1 23:51:54 2016 NAKAMURA Usaku <usa@ruby-lang.org> + + * test/lib/test/unit.rb (Options#non_options): fixed wrong regexp. + if both positives and negatives were specified, postives had to + be spcicifed from the beginning. + Sun May 1 21:00:07 2016 NAKAMURA Usaku <usa@ruby-lang.org> * win32/win32.c: drop Win2K support. diff --git a/test/lib/test/unit.rb b/test/lib/test/unit.rb index c5dd29b0cf..d34e11afa7 100644 --- a/test/lib/test/unit.rb +++ b/test/lib/test/unit.rb @@ -110,7 +110,7 @@ module Test end unless negative.empty? negative = Regexp.union(*negative.map! {|s| s[neg_pat, 1]}) - filter = /\A(?!.*#{negative})#{filter}/ + filter = /\A(?=.*#{filter})(?!.*#{negative})/ end if Regexp === filter # bypass conversion in minitest |