danger-undercover 1.1.0 → 2.0.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/.github/workflows/test.yml +3 -2
- data/.rubocop.yml +1 -0
- data/.tool-versions +1 -0
- data/Gemfile.lock +73 -51
- data/danger-undercover.gemspec +3 -2
- data/lib/undercover/cli.rb +1 -3
- data/lib/undercover/gem_version.rb +1 -1
- data/lib/undercover/plugin.rb +1 -1
- data/spec/cli_spec.rb +1 -1
- data/spec/undercover_spec.rb +2 -2
- metadata +8 -6
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: ad75ef7f5aea7e9a30520fb2147d7c86a4912aa73df8b1625f6f16812320ee07
|
4
|
+
data.tar.gz: 929273dc9dab6a2d6afd6064f145a5b10dd5a66eff42aa878315ecf6f76291ae
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: d9ff31aa72c7a44668ef5dceb7d62f9b1a34ad6b85d71cc6f81d6be847893ec5ba664374a1a491cf4db6fd8e8c82d53e4ca3870349a309759dbed51ac4e624df
|
7
|
+
data.tar.gz: ba6ae65dcd59ec7dae27f20093b4a6c2ba9eb9f693cef7a0fe2227d8d467725eec5cc88fc25965868676201e3b8cd875f7b4004111c4807ad51768c65986ec89
|
data/.github/workflows/test.yml
CHANGED
@@ -13,16 +13,17 @@ jobs:
|
|
13
13
|
|
14
14
|
strategy:
|
15
15
|
matrix:
|
16
|
-
ruby: [ '2.
|
16
|
+
ruby: [ '2.7', '3.0', '3.1' ]
|
17
17
|
|
18
18
|
name: Ruby ${{ matrix.ruby }}
|
19
19
|
|
20
20
|
steps:
|
21
21
|
- uses: actions/checkout@v2
|
22
22
|
|
23
|
-
- uses:
|
23
|
+
- uses: ruby/setup-ruby@v1
|
24
24
|
with:
|
25
25
|
ruby-version: ${{ matrix.ruby }}
|
26
|
+
bundler-cache: true
|
26
27
|
|
27
28
|
- name: Cache gems
|
28
29
|
uses: actions/cache@v1
|
data/.rubocop.yml
CHANGED
data/.tool-versions
ADDED
@@ -0,0 +1 @@
|
|
1
|
+
ruby 3.0.1
|
data/Gemfile.lock
CHANGED
@@ -1,16 +1,16 @@
|
|
1
1
|
PATH
|
2
2
|
remote: .
|
3
3
|
specs:
|
4
|
-
danger-undercover (
|
4
|
+
danger-undercover (2.0.0)
|
5
5
|
danger-plugin-api (~> 1.0)
|
6
6
|
|
7
7
|
GEM
|
8
8
|
remote: https://rubygems.org/
|
9
9
|
specs:
|
10
|
-
addressable (2.
|
10
|
+
addressable (2.8.0)
|
11
11
|
public_suffix (>= 2.0.2, < 5.0)
|
12
|
-
ast (2.4.
|
13
|
-
claide (1.0
|
12
|
+
ast (2.4.2)
|
13
|
+
claide (1.1.0)
|
14
14
|
claide-plugins (0.9.2)
|
15
15
|
cork
|
16
16
|
nap
|
@@ -19,7 +19,7 @@ GEM
|
|
19
19
|
colored2 (3.1.2)
|
20
20
|
cork (0.3.0)
|
21
21
|
colored2 (~> 3.1)
|
22
|
-
danger (8.
|
22
|
+
danger (8.4.2)
|
23
23
|
claide (~> 1.0)
|
24
24
|
claide-plugins (>= 0.9.2)
|
25
25
|
colored2 (~> 3.1)
|
@@ -31,26 +31,46 @@ GEM
|
|
31
31
|
kramdown-parser-gfm (~> 1.0)
|
32
32
|
no_proxy_fix
|
33
33
|
octokit (~> 4.7)
|
34
|
-
terminal-table (
|
34
|
+
terminal-table (>= 1, < 4)
|
35
35
|
danger-plugin-api (1.0.0)
|
36
36
|
danger (> 2.0)
|
37
|
-
diff-lcs (1.
|
38
|
-
faraday (1.
|
39
|
-
|
40
|
-
|
37
|
+
diff-lcs (1.5.0)
|
38
|
+
faraday (1.9.3)
|
39
|
+
faraday-em_http (~> 1.0)
|
40
|
+
faraday-em_synchrony (~> 1.0)
|
41
|
+
faraday-excon (~> 1.1)
|
42
|
+
faraday-httpclient (~> 1.0)
|
43
|
+
faraday-multipart (~> 1.0)
|
44
|
+
faraday-net_http (~> 1.0)
|
45
|
+
faraday-net_http_persistent (~> 1.0)
|
46
|
+
faraday-patron (~> 1.0)
|
47
|
+
faraday-rack (~> 1.0)
|
48
|
+
faraday-retry (~> 1.0)
|
49
|
+
ruby2_keywords (>= 0.0.4)
|
50
|
+
faraday-em_http (1.0.0)
|
51
|
+
faraday-em_synchrony (1.0.0)
|
52
|
+
faraday-excon (1.1.0)
|
41
53
|
faraday-http-cache (2.2.0)
|
42
54
|
faraday (>= 0.8)
|
43
|
-
|
44
|
-
|
45
|
-
|
55
|
+
faraday-httpclient (1.0.1)
|
56
|
+
faraday-multipart (1.0.3)
|
57
|
+
multipart-post (>= 1.2, < 3)
|
58
|
+
faraday-net_http (1.0.1)
|
59
|
+
faraday-net_http_persistent (1.2.0)
|
60
|
+
faraday-patron (1.0.0)
|
61
|
+
faraday-rack (1.0.0)
|
62
|
+
faraday-retry (1.0.3)
|
63
|
+
ffi (1.15.4)
|
64
|
+
formatador (0.3.0)
|
65
|
+
git (1.10.2)
|
46
66
|
rchardet (~> 1.8)
|
47
|
-
guard (2.
|
67
|
+
guard (2.18.0)
|
48
68
|
formatador (>= 0.2.4)
|
49
69
|
listen (>= 2.7, < 4.0)
|
50
70
|
lumberjack (>= 1.0.12, < 2.0)
|
51
71
|
nenv (~> 0.1)
|
52
72
|
notiffany (~> 0.0)
|
53
|
-
pry (>= 0.
|
73
|
+
pry (>= 0.13.0)
|
54
74
|
shellany (~> 0.0)
|
55
75
|
thor (>= 0.18.1)
|
56
76
|
guard-compat (1.2.1)
|
@@ -58,11 +78,11 @@ GEM
|
|
58
78
|
guard (~> 2.1)
|
59
79
|
guard-compat (~> 1.1)
|
60
80
|
rspec (>= 2.99.0, < 4.0)
|
61
|
-
kramdown (2.3.
|
81
|
+
kramdown (2.3.1)
|
62
82
|
rexml
|
63
83
|
kramdown-parser-gfm (1.1.0)
|
64
84
|
kramdown (~> 2.0)
|
65
|
-
listen (3.
|
85
|
+
listen (3.7.0)
|
66
86
|
rb-fsevent (~> 0.10, >= 0.10.3)
|
67
87
|
rb-inotify (~> 0.9, >= 0.9.10)
|
68
88
|
lumberjack (1.2.8)
|
@@ -74,60 +94,62 @@ GEM
|
|
74
94
|
notiffany (0.1.3)
|
75
95
|
nenv (~> 0.1)
|
76
96
|
shellany (~> 0.0)
|
77
|
-
octokit (4.
|
97
|
+
octokit (4.22.0)
|
78
98
|
faraday (>= 0.9)
|
79
99
|
sawyer (~> 0.8.0, >= 0.5.3)
|
80
100
|
open4 (1.3.4)
|
81
|
-
parallel (1.
|
82
|
-
parser (
|
101
|
+
parallel (1.21.0)
|
102
|
+
parser (3.1.0.0)
|
83
103
|
ast (~> 2.4.1)
|
84
|
-
pry (0.
|
104
|
+
pry (0.14.1)
|
85
105
|
coderay (~> 1.1)
|
86
106
|
method_source (~> 1.0)
|
87
107
|
public_suffix (4.0.6)
|
88
108
|
rainbow (3.0.0)
|
89
|
-
rake (13.0.
|
90
|
-
rb-fsevent (0.
|
109
|
+
rake (13.0.6)
|
110
|
+
rb-fsevent (0.11.0)
|
91
111
|
rb-inotify (0.10.1)
|
92
112
|
ffi (~> 1.0)
|
93
113
|
rchardet (1.8.0)
|
94
|
-
regexp_parser (
|
95
|
-
rexml (3.2.
|
96
|
-
rspec (3.
|
97
|
-
rspec-core (~> 3.
|
98
|
-
rspec-expectations (~> 3.
|
99
|
-
rspec-mocks (~> 3.
|
100
|
-
rspec-core (3.
|
101
|
-
rspec-support (~> 3.
|
102
|
-
rspec-expectations (3.
|
114
|
+
regexp_parser (2.2.0)
|
115
|
+
rexml (3.2.5)
|
116
|
+
rspec (3.10.0)
|
117
|
+
rspec-core (~> 3.10.0)
|
118
|
+
rspec-expectations (~> 3.10.0)
|
119
|
+
rspec-mocks (~> 3.10.0)
|
120
|
+
rspec-core (3.10.1)
|
121
|
+
rspec-support (~> 3.10.0)
|
122
|
+
rspec-expectations (3.10.1)
|
103
123
|
diff-lcs (>= 1.2.0, < 2.0)
|
104
|
-
rspec-support (~> 3.
|
105
|
-
rspec-mocks (3.
|
124
|
+
rspec-support (~> 3.10.0)
|
125
|
+
rspec-mocks (3.10.2)
|
106
126
|
diff-lcs (>= 1.2.0, < 2.0)
|
107
|
-
rspec-support (~> 3.
|
108
|
-
rspec-support (3.
|
109
|
-
rubocop (
|
127
|
+
rspec-support (~> 3.10.0)
|
128
|
+
rspec-support (3.10.3)
|
129
|
+
rubocop (1.24.1)
|
110
130
|
parallel (~> 1.10)
|
111
|
-
parser (>=
|
131
|
+
parser (>= 3.0.0.0)
|
112
132
|
rainbow (>= 2.2.2, < 4.0)
|
113
|
-
regexp_parser (>= 1.8)
|
133
|
+
regexp_parser (>= 1.8, < 3.0)
|
114
134
|
rexml
|
115
|
-
rubocop-ast (>=
|
135
|
+
rubocop-ast (>= 1.15.1, < 2.0)
|
116
136
|
ruby-progressbar (~> 1.7)
|
117
|
-
unicode-display_width (>= 1.4.0, <
|
118
|
-
rubocop-ast (
|
119
|
-
parser (>=
|
120
|
-
ruby-progressbar (1.
|
121
|
-
ruby2_keywords (0.0.
|
137
|
+
unicode-display_width (>= 1.4.0, < 3.0)
|
138
|
+
rubocop-ast (1.15.1)
|
139
|
+
parser (>= 3.0.1.1)
|
140
|
+
ruby-progressbar (1.11.0)
|
141
|
+
ruby2_keywords (0.0.5)
|
122
142
|
sawyer (0.8.2)
|
123
143
|
addressable (>= 2.3.5)
|
124
144
|
faraday (> 0.8, < 2.0)
|
125
145
|
shellany (0.0.1)
|
126
|
-
terminal-table (
|
127
|
-
unicode-display_width (
|
128
|
-
thor (1.
|
129
|
-
unicode-display_width (1.
|
130
|
-
|
146
|
+
terminal-table (3.0.2)
|
147
|
+
unicode-display_width (>= 1.1.1, < 3)
|
148
|
+
thor (1.2.1)
|
149
|
+
unicode-display_width (2.1.0)
|
150
|
+
webrick (1.7.0)
|
151
|
+
yard (0.9.27)
|
152
|
+
webrick (~> 1.7.0)
|
131
153
|
|
132
154
|
PLATFORMS
|
133
155
|
ruby
|
@@ -145,4 +167,4 @@ DEPENDENCIES
|
|
145
167
|
yard
|
146
168
|
|
147
169
|
BUNDLED WITH
|
148
|
-
2.
|
170
|
+
2.3.3
|
data/danger-undercover.gemspec
CHANGED
@@ -2,7 +2,7 @@
|
|
2
2
|
|
3
3
|
lib = File.expand_path('lib', __dir__)
|
4
4
|
$LOAD_PATH.unshift(lib) unless $LOAD_PATH.include?(lib)
|
5
|
-
require 'undercover/gem_version
|
5
|
+
require 'undercover/gem_version'
|
6
6
|
|
7
7
|
Gem::Specification.new do |spec|
|
8
8
|
spec.name = 'danger-undercover'
|
@@ -13,8 +13,9 @@ Gem::Specification.new do |spec|
|
|
13
13
|
spec.summary = 'A Danger plugin for Undercover gem'
|
14
14
|
spec.homepage = 'https://github.com/nimblehq/danger-undercover'
|
15
15
|
spec.license = 'MIT'
|
16
|
+
spec.metadata = { 'rubygems_mfa_required' => 'true' }
|
16
17
|
|
17
|
-
spec.required_ruby_version = '
|
18
|
+
spec.required_ruby_version = '>= 2.7'
|
18
19
|
spec.files = `git ls-files`.split($INPUT_RECORD_SEPARATOR)
|
19
20
|
spec.executables = spec.files.grep(%r{^bin/}) { |f| File.basename(f) }
|
20
21
|
spec.test_files = spec.files.grep(%r{^(test|spec|features)/})
|
data/lib/undercover/cli.rb
CHANGED
@@ -13,9 +13,7 @@ module DangerUndercover
|
|
13
13
|
def run(args = nil)
|
14
14
|
undercover_output = `undercover #{args&.join(' ')}`
|
15
15
|
|
16
|
-
File.
|
17
|
-
f.write(undercover_output)
|
18
|
-
end
|
16
|
+
File.write(output_file, undercover_output)
|
19
17
|
|
20
18
|
undercover_output
|
21
19
|
end
|
data/lib/undercover/plugin.rb
CHANGED
@@ -27,7 +27,7 @@ module Danger
|
|
27
27
|
def report(undercover_path = DEFAULT_PATH, sticky: true)
|
28
28
|
return fail('Undercover: coverage report cannot be found.') unless valid_file? undercover_path
|
29
29
|
|
30
|
-
report = File.
|
30
|
+
report = File.read(undercover_path, encoding: 'UTF-8')
|
31
31
|
|
32
32
|
if report.match(/some methods have no test coverage/)
|
33
33
|
warn(report, sticky: sticky)
|
data/spec/cli_spec.rb
CHANGED
data/spec/undercover_spec.rb
CHANGED
@@ -23,7 +23,7 @@ module Danger
|
|
23
23
|
it 'shows success message if nothing to report' do
|
24
24
|
report_path = 'spec/fixtures/undercover_passed.txt'
|
25
25
|
@undercover.report(report_path)
|
26
|
-
report = File.
|
26
|
+
report = File.read(report_path)
|
27
27
|
|
28
28
|
expect(@dangerfile.status_report[:messages]).to eq([report])
|
29
29
|
end
|
@@ -31,7 +31,7 @@ module Danger
|
|
31
31
|
it 'shows warnings if undercover has a report' do
|
32
32
|
report_path = 'spec/fixtures/undercover_failed.txt'
|
33
33
|
@undercover.report(report_path)
|
34
|
-
report = File.
|
34
|
+
report = File.read(report_path)
|
35
35
|
|
36
36
|
expect(@dangerfile.status_report[:warnings]).to eq([report])
|
37
37
|
end
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: danger-undercover
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version:
|
4
|
+
version: 2.0.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Nimble
|
@@ -9,7 +9,7 @@ authors:
|
|
9
9
|
autorequire:
|
10
10
|
bindir: bin
|
11
11
|
cert_chain: []
|
12
|
-
date:
|
12
|
+
date: 2022-01-19 00:00:00.000000000 Z
|
13
13
|
dependencies:
|
14
14
|
- !ruby/object:Gem::Dependency
|
15
15
|
name: danger-plugin-api
|
@@ -166,6 +166,7 @@ files:
|
|
166
166
|
- ".github/workflows/test.yml"
|
167
167
|
- ".gitignore"
|
168
168
|
- ".rubocop.yml"
|
169
|
+
- ".tool-versions"
|
169
170
|
- Gemfile
|
170
171
|
- Gemfile.lock
|
171
172
|
- Guardfile
|
@@ -187,23 +188,24 @@ files:
|
|
187
188
|
homepage: https://github.com/nimblehq/danger-undercover
|
188
189
|
licenses:
|
189
190
|
- MIT
|
190
|
-
metadata:
|
191
|
+
metadata:
|
192
|
+
rubygems_mfa_required: 'true'
|
191
193
|
post_install_message:
|
192
194
|
rdoc_options: []
|
193
195
|
require_paths:
|
194
196
|
- lib
|
195
197
|
required_ruby_version: !ruby/object:Gem::Requirement
|
196
198
|
requirements:
|
197
|
-
- - "
|
199
|
+
- - ">="
|
198
200
|
- !ruby/object:Gem::Version
|
199
|
-
version: '2.
|
201
|
+
version: '2.7'
|
200
202
|
required_rubygems_version: !ruby/object:Gem::Requirement
|
201
203
|
requirements:
|
202
204
|
- - ">="
|
203
205
|
- !ruby/object:Gem::Version
|
204
206
|
version: '0'
|
205
207
|
requirements: []
|
206
|
-
rubygems_version: 3.
|
208
|
+
rubygems_version: 3.3.5
|
207
209
|
signing_key:
|
208
210
|
specification_version: 4
|
209
211
|
summary: A Danger plugin for Undercover gem
|