xcov 1.7.0 → 1.7.1
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/xcov/model/target.rb +3 -4
- data/lib/xcov/version.rb +1 -1
- metadata +3 -4
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 18dce8e7c8f0139148548de4cc8ac57523f382e72a32bbcb09054a4856c87a8e
|
4
|
+
data.tar.gz: dd95fa78b0bc924dbb7cb457a58cc7f4bcc1462be98ebc805a7b249f1574ae9f
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 4cbdcd8b07f093acd7e3af63b4c7a95df603b93464694265aa233a0d765e517f2c7ee61dd1e21babcd827491f484fc3f83720857ca32d3d2dde7344628b9d8ad
|
7
|
+
data.tar.gz: a0c47d29fa3ba3604dac5e22dbd3049053a6bac20a99f9a18bc5b52ded4692c5488f1c37d860ad1b2f73f2419d8b615d7e555d3701260b27d55be5615cd2de6c
|
data/lib/xcov/model/target.rb
CHANGED
@@ -7,10 +7,10 @@ module Xcov
|
|
7
7
|
attr_accessor :files
|
8
8
|
attr_accessor :file_templates
|
9
9
|
|
10
|
-
def initialize(name,
|
10
|
+
def initialize(name, files)
|
11
11
|
@name = CGI::escapeHTML(name)
|
12
12
|
@files = files
|
13
|
-
@coverage = coverage
|
13
|
+
@coverage = files.count == 0 ? 0.0 : files.reduce(0) { |acc, file| acc + file.coverage.to_f } / files.count
|
14
14
|
@displayable_coverage = self.create_displayable_coverage
|
15
15
|
@coverage_color = self.create_coverage_color
|
16
16
|
@id = Target.create_id(name)
|
@@ -53,12 +53,11 @@ module Xcov
|
|
53
53
|
|
54
54
|
def self.map(dictionary)
|
55
55
|
name = dictionary["name"]
|
56
|
-
coverage = dictionary["coverage"]
|
57
56
|
files = dictionary["files"].map { |file| Source.map(file)}
|
58
57
|
files = files.sort &by_coverage_with_ignored_at_the_end
|
59
58
|
non_ignored_files = Target.select_non_ignored_files(files)
|
60
59
|
|
61
|
-
Target.new(name,
|
60
|
+
Target.new(name, non_ignored_files)
|
62
61
|
end
|
63
62
|
|
64
63
|
def self.by_coverage_with_ignored_at_the_end
|
data/lib/xcov/version.rb
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: xcov
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.7.
|
4
|
+
version: 1.7.1
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Carlos Vidal
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date:
|
11
|
+
date: 2020-01-29 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: fastlane
|
@@ -209,8 +209,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
209
209
|
- !ruby/object:Gem::Version
|
210
210
|
version: '0'
|
211
211
|
requirements: []
|
212
|
-
|
213
|
-
rubygems_version: 2.7.6
|
212
|
+
rubygems_version: 3.0.3
|
214
213
|
signing_key:
|
215
214
|
specification_version: 4
|
216
215
|
summary: xcov is a friendly visualizer for Xcode's code coverage files
|