testrbl 0.8.0 → 0.9.0

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
- SHA1:
3
- metadata.gz: 1013ac41c62b29ae793ebc58d7f32967a3031f32
4
- data.tar.gz: 35b899c48f919c85c958e26ed8ded9f6f4d11933
2
+ SHA256:
3
+ metadata.gz: 49534563e8d2c43647b84e457e1fd35873167eaa70b1687a63217d6005a11c5c
4
+ data.tar.gz: e5bc529fee2b1791547b4dc0f053c7138de70a9477b325d9fd2981eb8c040e40
5
5
  SHA512:
6
- metadata.gz: 7aa118ff074c25054c0e29e96da7f693717b8775b08595c8e6c68b2f1364b99c8f3421dac0c423a465bde628ec86870105fca0cf58153b1967ad7fa172d3560e
7
- data.tar.gz: 5447f57db28b74d17fc9aae974592058e6aa5825f0df15b10c99318826dd5336e8bb5f63c78aaad9c5de4d80c40c62172b8cca83dc2573a2815ccaeba3c73664
6
+ metadata.gz: d1222308ab263f3098cdad5f0a99bf5abddecc6b61a7b5cb2a80066fefa1541ac88fbe1a722aa0e5182fea897df2ad6ad50a3afe20f91326a455de220e9fdb12
7
+ data.tar.gz: b5f502bcb6064306ffe14d6d9b58dd01a4e1f5c214720de65cec275047e1f60d8366c5beeb656bd71ecd172493a9924a3ae69e154340f1236d44aa147b5f31a3
@@ -1,7 +1,7 @@
1
1
  PATH
2
2
  remote: .
3
3
  specs:
4
- testrbl (0.8.0)
4
+ testrbl (0.9.0)
5
5
 
6
6
  GEM
7
7
  remote: https://rubygems.org/
@@ -40,4 +40,4 @@ DEPENDENCIES
40
40
  testrbl!
41
41
 
42
42
  BUNDLED WITH
43
- 1.12.3
43
+ 2.1.4
@@ -2,9 +2,9 @@ require 'testrbl/version'
2
2
 
3
3
  module Testrbl
4
4
  PATTERNS = [
5
- /^(\s+)(should|test|it)\s+['"](.*)['"]\s+do\s*(?:#.*)?$/,
6
- /^(\s+)(context|describe)\s+['"]?(.*?)['"]?\s+do\s*(?:#.*)?$/,
7
- /^(\s+)def\s+(test_)([a-z_\d]+)\s*(?:#.*)?$/
5
+ /^(\s+)(should|test|it)(\s+|\s*\(\s*)['"](.*)['"](\s*\))?\s+do\s*(?:#.*)?$/,
6
+ /^(\s+)(context|describe)(\s+|\s*\(\s*)['"]?(.*?)['"]?(\s*\))?\s+do\s*(?:#.*)?$/,
7
+ /^(\s+)def(\s+)(test_)([a-z_\d]+)\s*(?:#.*)?$/
8
8
  ]
9
9
 
10
10
  OPTION_WITH_ARGUMENT = ["-I", "-r", "-n", "--name", "-e", "--exclude", "-s", "--seed"]
@@ -154,7 +154,7 @@ module Testrbl
154
154
  def test_pattern_from_line(line)
155
155
  PATTERNS.each do |r|
156
156
  next unless line =~ r
157
- whitespace, method, test_name = $1, $2, $3
157
+ whitespace, method, test_name = $1, $2, $4
158
158
  return [whitespace, test_pattern_from_match(method, test_name)]
159
159
  end
160
160
  nil
@@ -1,3 +1,3 @@
1
1
  module Testrbl
2
- VERSION = '0.8.0'
2
+ VERSION = '0.9.0'
3
3
  end
@@ -346,6 +346,16 @@ describe Testrbl do
346
346
  it "b./_-d" do
347
347
  puts "-EFG-"
348
348
  end
349
+
350
+ it("f-g") do
351
+ puts "-HIJ-"
352
+ end
353
+ end
354
+
355
+ describe("h-j") do
356
+ it "i-k" do
357
+ puts "-KLM-"
358
+ end
349
359
  end
350
360
  RUBY
351
361
  end
@@ -370,6 +380,14 @@ describe Testrbl do
370
380
  it "runs nested it" do
371
381
  run_line("13").should == ["CDE"]
372
382
  end
383
+
384
+ it "runs it with parens" do
385
+ run_line("28").should == ["HIJ"]
386
+ end
387
+
388
+ it "runs describe with parens" do
389
+ run_line("33").should == ["KLM"]
390
+ end
373
391
  end
374
392
 
375
393
  context "multiple files / folders" do
@@ -623,7 +641,7 @@ describe Testrbl do
623
641
  call(" it \"xX ._-.. ___ Xx\" do\n").should == [" ", "#test_\\d+_xX \\._\\-\\.\\. ___ Xx$"]
624
642
  end
625
643
 
626
- it "finds with pecial characters" do
644
+ it "finds with special characters" do
627
645
  call(" it \"hmm? it's weird\\\"?\" do\n").should == [" ", "#test_\\d+_hmm\\? it.s weird\\\\\"\\?$"]
628
646
  end
629
647
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: testrbl
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.8.0
4
+ version: 0.9.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Michael Grosser
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2016-07-09 00:00:00.000000000 Z
11
+ date: 2020-11-05 00:00:00.000000000 Z
12
12
  dependencies: []
13
13
  description:
14
14
  email: michael@grosser.it
@@ -47,8 +47,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
47
47
  - !ruby/object:Gem::Version
48
48
  version: '0'
49
49
  requirements: []
50
- rubyforge_project:
51
- rubygems_version: 2.4.5.1
50
+ rubygems_version: 3.1.3
52
51
  signing_key:
53
52
  specification_version: 4
54
53
  summary: Run ruby Test::Unit/Shoulda tests by line-number / folder / the dozen