spectator 1.2.10 → 1.2.11

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 8fd9aecc75255719e0ea6df36d31f6a4f2f13d70
4
- data.tar.gz: 58599e92025c1647fce2026ef34145b02ac8d6ce
3
+ metadata.gz: 3250e47a3847d52f1c8b48be5b9c922a5cf38a83
4
+ data.tar.gz: f37e2c2263492ccce1d604aabb257a086935ddcb
5
5
  SHA512:
6
- metadata.gz: 982b855f06baf816669fe0843f20bc6e400d478de819511cc9f818ed14b529974b395aad8c90ba460e0a83094a89844067b7149d3a0e584f7b5c2e92456b86fc
7
- data.tar.gz: 7a03f165f59e794a7dc0868507581c893c3f627a32b3ad46704bc74ce230bbf5d65615a79406eca9ea029846bed6eba76602d247abc142bd535d4d3129115ea8
6
+ metadata.gz: 2ab6190cc9fd6f03e4bda7deca8191c9be17cc30d8e148f86edd2d1513294922f15c39e60b2a359df4fffd6cba3707b6ee2130a724d4500272a138e8c0490651
7
+ data.tar.gz: ec6565d41c1195a15b757a6a91e8a73776a99df708e1639e76e481a134906a7bba97dfb724f1c1a324a699f70a28d6b405cacdd524dbeefc8efd4b28cd0ec5a1
data/README.md CHANGED
@@ -22,12 +22,12 @@ Works with RSpec-1 and RSpec-2 (looks for a `.rspec` file in the project root).
22
22
 
23
23
  Launch `spectator` in a terminal and go back to code!
24
24
 
25
- The normal behavior is similar to `autotest --fast-start --no-full-after-failed`
25
+ The normal behavior is similar to `autotest --fast-start --no-full-after-failed`
26
26
  but gives the user a bit more control over execution. By hitting CTRL+C (or CMD+. on OSX)
27
27
  you get the following prompt:
28
28
 
29
29
  ^C (Interrupted with CTRL+C)
30
- --- What to do now? (q=quit, a=all-specs):
30
+ --- What to do now? (q=quit, a=all-specs):
31
31
 
32
32
  Type `q` and `ENTER` (or `CTRL+C` again) to quit.
33
33
 
@@ -38,17 +38,62 @@ Type `a` and `ENTER` (or `CTRL+C` again) to execute the whole suite of specs.
38
38
 
39
39
  If you want to override some path matching:
40
40
 
41
- ```ruby
42
- spectate do
43
- case path
44
- when %r{lib/calibration_with_coefficients}
45
- specs.grep(%r{models/(logarithmic|polynomial)_calibration})
46
- when %r{app/models/telemetry_parameter}
47
- specs.grep(%r{models/telemetry_parameter})
48
- end
49
- end
41
+ **`BASE_DIR_GLOB`:**
42
+
43
+ The glob that expanded will list the directories that contains the code. **Default:**
44
+
45
+
46
+ **`SPEC_DIR_GLOB`:**
47
+
48
+ The glob that expanded will list the directories that contains the specs. **Default:**
49
+
50
+ **`RSPEC_COMMAND`:**
51
+
52
+ The full command that will run your specs. **Default:** `bundle exec rspec` (or `bundle exec spec` for RSpec 1.x)
53
+
54
+
55
+ ### Examples
56
+
57
+ #### Inline ENV variables
58
+
59
+ ```shell
60
+ # this will match lib/opal/parser.rb to spec/cli/parser.rb
61
+ BASE_DIR_GLOB='lib/opal' SPEC_DIR_GLOB='spec/cli' spectator
62
+ ```
63
+
64
+
65
+ #### Exported ENV variables
66
+
67
+ ```shell
68
+ export BASE_DIR_GLOB="{opal/corelib,stdlib}"
69
+ export SPEC_DIR_GLOB="spec/{corelib,stdlib}"
70
+ export RSPEC_COMMAND="bundle exec mspec run -t ./bin/opal -I$(dirname $(gem which mspec)) -Ilib -rmspec/opal/mspec_fixes.rb"
71
+ spectator
72
+ ```
73
+
74
+
75
+ #### With a `.spectator` config file
76
+
77
+ ```yaml
78
+ # contents of ".spectator" file
79
+ BASE_DIR_GLOB: 'lib/opal'
80
+ SPEC_DIR_GLOB: 'spec/cli'
50
81
  ```
51
82
 
83
+ spectator
84
+
85
+
86
+ #### Specifying a custom config file
87
+
88
+ ```shell
89
+ # contents of ".my-spectator-config" file
90
+ BASE_DIR_GLOB: 'lib/opal'
91
+ SPEC_DIR_GLOB: 'spec/cli'
92
+ ```
93
+
94
+ spectator .my-spectator-config
95
+
52
96
 
97
+ ## License
53
98
 
54
99
  Copyright © 2011-2012 Elia Schito, released under the [MIT license](https://github.com/elia/spectator/blob/master/MIT-LICENSE)
data/bin/spectator CHANGED
@@ -9,4 +9,10 @@ end
9
9
 
10
10
  require 'spectator'
11
11
 
12
+ require 'yaml'
13
+ config_file = ARGV.first || '.spectator'
14
+ YAML.load_file(config).each do |name, value|
15
+ ENV[name] ||= value
16
+ end if File.exist? config_file
17
+
12
18
  Spectator.run
@@ -1,3 +1,3 @@
1
1
  module Spectator
2
- VERSION = '1.2.10'
2
+ VERSION = '1.2.11'
3
3
  end
data/spectator.gemspec CHANGED
@@ -24,6 +24,6 @@ Gem::Specification.new do |s|
24
24
  s.add_dependency 'term-ansicolor', '~> 1.2.2'
25
25
  s.add_dependency 'notify', '~> 0.5.2'
26
26
 
27
- s.add_development_dependency 'rake', '~> 0.9'
27
+ s.add_development_dependency 'rake', '~> 10'
28
28
  s.add_development_dependency 'bundler', '~> 1.0'
29
29
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: spectator
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.2.10
4
+ version: 1.2.11
5
5
  platform: ruby
6
6
  authors:
7
7
  - Elia
@@ -9,7 +9,7 @@ authors:
9
9
  autorequire:
10
10
  bindir: bin
11
11
  cert_chain: []
12
- date: 2014-04-16 00:00:00.000000000 Z
12
+ date: 2014-04-24 00:00:00.000000000 Z
13
13
  dependencies:
14
14
  - !ruby/object:Gem::Dependency
15
15
  name: listen
@@ -59,14 +59,14 @@ dependencies:
59
59
  requirements:
60
60
  - - "~>"
61
61
  - !ruby/object:Gem::Version
62
- version: '0.9'
62
+ version: '10'
63
63
  type: :development
64
64
  prerelease: false
65
65
  version_requirements: !ruby/object:Gem::Requirement
66
66
  requirements:
67
67
  - - "~>"
68
68
  - !ruby/object:Gem::Version
69
- version: '0.9'
69
+ version: '10'
70
70
  - !ruby/object:Gem::Dependency
71
71
  name: bundler
72
72
  requirement: !ruby/object:Gem::Requirement