deep-cover 0.7.7 → 0.7.8
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 +4 -4
- data/.travis.yml +1 -0
- data/CHANGELOG.md +1 -1
- data/lib/deep_cover/cli.rb +11 -12
- data/lib/deep_cover/cli/commands/exec.rb +1 -1
- metadata +4 -4
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 026a2a8870f332d242fcbed175eb1a87a54ff0f552d834138da50e57069762f5
|
4
|
+
data.tar.gz: 1c817d02a7ded04408f83551bcbc66e3fee66b93727d31cc05c2e2f88e116ee7
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 37e78938aecf7f54503a978376a4eaa54e379d284896a50ac360699af4e7aae476eec9112c3ba59bf6ad7def7f19f51493dd87ef820e233dcda6b3e0d98e2dcb
|
7
|
+
data.tar.gz: 15bc27c6cca6d908af2a58a50ee177c1d6b6a20a8f5221d5055ce556c835082bc829289c6187dfeab5386e227ee8e0b5318df1314d71542b73c6dcd3d63200a2
|
data/.travis.yml
CHANGED
data/CHANGELOG.md
CHANGED
data/lib/deep_cover/cli.rb
CHANGED
@@ -11,6 +11,13 @@ module DeepCover
|
|
11
11
|
bootstrap
|
12
12
|
|
13
13
|
class CLI < Thor
|
14
|
+
# Consider defaults only for display
|
15
|
+
def self.build_option(arg, options, scope)
|
16
|
+
default = options.delete(:default)
|
17
|
+
options[:desc] = "#{options[:desc]} (default: #{default})" if default
|
18
|
+
super(arg, options, scope)
|
19
|
+
end
|
20
|
+
|
14
21
|
require_relative 'cli/tools'
|
15
22
|
|
16
23
|
# Just fail when you get an unknown option
|
@@ -25,11 +32,9 @@ module DeepCover
|
|
25
32
|
default_command :short_help
|
26
33
|
|
27
34
|
# Adding all of the ignore-something class options
|
28
|
-
|
29
|
-
[
|
30
|
-
|
31
|
-
OPTIONALLY_COVERED_MAP.each do |cli_option, short_name|
|
32
|
-
default = DeepCover.config.ignore_uncovered.include?(short_name)
|
35
|
+
OPTIONALLY_COVERED.each do |filter|
|
36
|
+
cli_option = FILTER_NAME[filter]
|
37
|
+
default = DeepCover.config[cli_option]
|
33
38
|
class_option cli_option, type: :boolean, default: default
|
34
39
|
end
|
35
40
|
|
@@ -50,19 +55,13 @@ module DeepCover
|
|
50
55
|
new_options = options.dup
|
51
56
|
new_options[:output] = false if ['false', 'f', ''].include?(new_options[:output])
|
52
57
|
|
53
|
-
# Turn all the ignore-x into entries in :ignore_uncovered
|
54
|
-
ignored = new_options[:ignore_uncovered] = []
|
55
|
-
OPTIONALLY_COVERED_MAP.each do |cli_option, option|
|
56
|
-
ignored << option if new_options.delete(cli_option)
|
57
|
-
end
|
58
|
-
|
59
58
|
@processed_options = new_options.transform_keys(&:to_sym)
|
60
59
|
end
|
61
60
|
|
62
61
|
# Before we actually execute any of the commands, we want to change directory if that option was given.
|
63
62
|
# And then we want to setup the configuration
|
64
63
|
def invoke_command(*args)
|
65
|
-
if options[:change_directory]
|
64
|
+
if options[:change_directory]
|
66
65
|
root_path = File.expand_path(options[:change_directory])
|
67
66
|
unless File.exist?(root_path)
|
68
67
|
warn set_color(DeepCover::Tools.strip_heredoc(<<-MSG), :red)
|
@@ -29,7 +29,7 @@ module DeepCover
|
|
29
29
|
DeepCover.delete_trackers
|
30
30
|
exit_code = Tools.run_command_or_exit(shell, env_var, *command_parts)
|
31
31
|
coverage = Coverage.load
|
32
|
-
puts coverage.report(**
|
32
|
+
puts coverage.report(**DeepCover.config)
|
33
33
|
exit(exit_code)
|
34
34
|
end
|
35
35
|
end
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: deep-cover
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.7.
|
4
|
+
version: 0.7.8
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Marc-André Lafortune
|
@@ -9,7 +9,7 @@ authors:
|
|
9
9
|
autorequire:
|
10
10
|
bindir: exe
|
11
11
|
cert_chain: []
|
12
|
-
date: 2020-
|
12
|
+
date: 2020-02-16 00:00:00.000000000 Z
|
13
13
|
dependencies:
|
14
14
|
- !ruby/object:Gem::Dependency
|
15
15
|
name: deep-cover-core
|
@@ -17,14 +17,14 @@ dependencies:
|
|
17
17
|
requirements:
|
18
18
|
- - '='
|
19
19
|
- !ruby/object:Gem::Version
|
20
|
-
version: 0.7.
|
20
|
+
version: 0.7.8
|
21
21
|
type: :runtime
|
22
22
|
prerelease: false
|
23
23
|
version_requirements: !ruby/object:Gem::Requirement
|
24
24
|
requirements:
|
25
25
|
- - '='
|
26
26
|
- !ruby/object:Gem::Version
|
27
|
-
version: 0.7.
|
27
|
+
version: 0.7.8
|
28
28
|
- !ruby/object:Gem::Dependency
|
29
29
|
name: highline
|
30
30
|
requirement: !ruby/object:Gem::Requirement
|