travis-ci
586 of 586 new or added lines in 35 files covered. (100.0%)
5028 of 5539 relevant lines covered (90.77%)
51.88 hits per line
1 |
module Guard |
4✔ |
|
module Commands |
4✔ |
|
class Scope |
4✔ |
|
def self.import |
4✔ |
|
Pry::Commands.create_command 'scope' do |
4✔ |
|
group 'Guard'
|
4✔ |
|
description 'Scope Guard actions to groups and plugins.'
|
4✔ |
8 |
|
|
|
banner <<-BANNER |
3 all except 1.9.3 ✔ |
10 |
Usage: scope <scope> |
|
11 |
|
|
12 |
Set the global Guard scope.
|
|
|
BANNER |
1 only 1.9.3 ✔ |
14 |
|
|
|
def process(*entries) |
4✔ |
|
scope, unknown = Guard::Interactor.convert_scope(entries) |
2 only 1.9.3 ✔ |
17 |
|
|
|
unless unknown.empty?
|
2 only 1.9.3 ✔ |
|
output.puts "Unknown scopes: #{unknown.join(',') }"
|
× |
|
return
|
× |
21 |
end
|
|
22 |
|
|
|
if scope[:plugins].empty? && scope[:groups].empty? |
2 only 1.9.3 ✔ |
|
output.puts 'Usage: scope <scope>'
|
1 only 1.9.3 ✔ |
|
return
|
1 only 1.9.3 ✔ |
26 |
end
|
|
27 |
|
|
28 |
Guard.scope = scope
|
1 only 1.9.3 ✔ |
29 |
end
|
|
30 |
end
|
|
31 |
end
|
|
32 |
end
|
|
33 |
end
|
|
34 |
end
|
|
35 |
|
|
|
Guard::Commands::Scope.import |
4✔ |