git-recommend 0.6.1 → 0.6.2

Sign up to get free protection for your applications and to get access to all the features.
Files changed (4) hide show
  1. checksums.yaml +4 -4
  2. data/lib/git_test.rb +6 -3
  3. data/lib/version.rb +1 -1
  4. metadata +2 -2
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: f040a80a831e1a88d78f93fecb757a2ae2869316
4
- data.tar.gz: 3620018ffd2cc07e0c609edcc8c05b51175abff3
3
+ metadata.gz: 8b3683fedd27c0dac591106dfe13acaf0835f5fa
4
+ data.tar.gz: c2c289259e8abc54a585a757abce3629549cf7b8
5
5
  SHA512:
6
- metadata.gz: 4d4319df6131751cd5b0f87c3bc3ece01d26f6c1dbc334326292c74200e397e76eed638c32e9ab516020f8f59ffe3876592e396b7f0a70aac15e363303048c4a
7
- data.tar.gz: aa663bb2c6f0b05642932d1bdddc3c8b9c8938b077b506a8471abf62f3c7ccb6185a7cb8026858b5cad5b910ac1aa43dacd190a255af933b2b81c791cbebb610
6
+ metadata.gz: 5769e0187c1be819946a34a3b07929a050a00502d4803f790aea4ed7683f606d2c02b613b0b572b1ab95e20a9b74a1648172514c163d3cf81f71ce46f8f4cfde
7
+ data.tar.gz: 0ccbb5f0ebe9fd9ebb31b5f593f421d1c764b2ddb3a5fd7893c2d33c2ca2182c2aa6cc25ad9ad33f956a67e427b04e4a72500992a0f17b0916c0eef41c1f56b1
data/lib/git_test.rb CHANGED
@@ -39,14 +39,17 @@ class GitTest < Thor
39
39
  max_cg = test_plan.map {|_,v| v['cg']}.max
40
40
  test_plan.each {|test,v| test_plan[test]['cg'] = v['cg']/max_cg}
41
41
 
42
- # print warnings to stderr if any
42
+ # print items with missing test mapping to stderr
43
+ uncovered = Hash.new
43
44
  [LHS,RHS].each do |side|
44
45
  items_in_plan = change_rec.map {|row| row[side]}.to_set
45
46
  if coverage[side].size < items_in_plan.size
46
- uncovered = items_in_plan - coverage[side]
47
- $stderr.puts "#{uncovered.size} #{side.gsub('_',' ')} were not covered by at least 1 test. The first 10 were: \n #{uncovered.take(10).join("\n")}"
47
+ uncovered[side+'_without_test_mapping'] = items_in_plan - coverage[side]
48
48
  end
49
49
  end
50
+ if !uncovered.empty?
51
+ $stderr.puts uncovered.to_json
52
+ end
50
53
  # print testplan to stdout
51
54
  $stdout.puts "test,impact,#{LHS}_covered,#{RHS}_covered"
52
55
  test_plan.sort_by {|k,v| [v[LHS].size,v[RHS].size].max}.each do |test,v|
data/lib/version.rb CHANGED
@@ -1,5 +1,5 @@
1
1
  module Git
2
2
  module Recommend
3
- VERSION = "0.6.1"
3
+ VERSION = "0.6.2"
4
4
  end
5
5
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: git-recommend
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.6.1
4
+ version: 0.6.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - Thomas Rolfsnes
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2017-02-13 00:00:00.000000000 Z
11
+ date: 2017-03-14 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: thor