miss_cleo 0.2.3 → 0.3.0

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 89fc739b1a1a6daee111c1143bf497c5403faca3
4
- data.tar.gz: 11b5d59375143f603a83450d0d816b63a5bf966f
3
+ metadata.gz: 5526982c7e9f09a0bb1de35173f80b73af561156
4
+ data.tar.gz: 4924b1e642ff6b9bdca2eb85bc693b586f17f6ad
5
5
  SHA512:
6
- metadata.gz: 30e19ae0fdfd13e4a1fa14181d8301dbfc35f6f805323fbbb0343964f495abc1f99914d98dadd2ebe883df9a628ccd138da481664f701b9a8f05e8a5591ce1c0
7
- data.tar.gz: 9ce1e27799123ebd16f2c39bc67c7aa6b3991e1c5077e3194090d7cd1b78b3fa1750e917bc6e4be46508c3f6cf53a1c1d23f907964cbed7fd4f1d5de511f659a
6
+ metadata.gz: 3e6efe54fea893824d305d614724043cdfd95d7b55eee155c12d6a7dea3f399b0ff0f4c01000d0cde5d3467806a82edd4647ca69991ed51d309e034803db87b2
7
+ data.tar.gz: ace430c95113e35f2874f6a12efada2d16b599b4cb1bb3934f118e77266fb0b00b2f7319d22005f4f3c99e4b2950b6d849adb197438fd5184659f1dc1ffb75c5
@@ -10,6 +10,22 @@ module MissCleo
10
10
  ([RUBY_PATH] + GEM_PATHS).any? { |path| file.include?(path) }
11
11
  end
12
12
  end
13
+
14
+ def self.normalize_paths(result_hash)
15
+ normalized_hash = Hash.new
16
+ result_hash.each do |key, value|
17
+ trimmed_key = key.gsub(/#{Regexp.quote(`pwd`.chomp)}/, "")
18
+ normalized_hash[trimmed_key] = value
19
+ end
20
+
21
+ normalized_hash
22
+ end
23
+
24
+ def self.filter_and_trim(result_hash)
25
+ filtered = filter_core(result_hash)
26
+ normalize_paths(filtered)
27
+ end
28
+
13
29
  end
14
30
 
15
31
  end
@@ -12,7 +12,7 @@ module MissCleo
12
12
  execute.call
13
13
  after = Coverage.peek_result
14
14
  if file_and_line = scenario.try(:file_colon_line)
15
- LOGS << [ file_and_line, before, after ]
15
+ LOGS << [ file_and_line, CoverageFilter.filter_and_trim(before), CoverageFilter.filter_and_trim(after) ]
16
16
  end
17
17
  end
18
18
 
@@ -15,8 +15,8 @@ module MissCleo
15
15
  before = Coverage.peek_result
16
16
  example.call
17
17
  after = Coverage.peek_result
18
- LOGS << [ example.location, CoverageFilter.filter_core(before),
19
- CoverageFilter.filter_core(after) ]
18
+ LOGS << [ example.location, CoverageFilter.filter_and_trim(before),
19
+ CoverageFilter.filter_and_trim(after) ]
20
20
  end
21
21
  end
22
22
  end
@@ -1,3 +1,3 @@
1
1
  module MissCleo
2
- VERSION = "0.2.3"
2
+ VERSION = "0.3.0"
3
3
  end
data/miss_cleo.gemspec CHANGED
@@ -6,7 +6,7 @@ require 'miss_cleo/version'
6
6
  Gem::Specification.new do |spec|
7
7
  spec.name = "miss_cleo"
8
8
  spec.version = MissCleo::VERSION
9
- spec.authors = ["Dean Hu", "Lee Ourand"]
9
+ spec.authors = ["Dean Hu", "Lee Ourand", "John Bernier"]
10
10
  spec.email = ["devs@gust.com"]
11
11
 
12
12
  spec.summary = %q{Predict your test failures}
metadata CHANGED
@@ -1,11 +1,12 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: miss_cleo
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.2.3
4
+ version: 0.3.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Dean Hu
8
8
  - Lee Ourand
9
+ - John Bernier
9
10
  autorequire:
10
11
  bindir: bin
11
12
  cert_chain: []