deep-cover 0.5.0 → 0.5.1
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/Gemfile +1 -1
- data/lib/deep_cover/auto_run.rb +1 -1
- data/lib/deep_cover/cli/debugger.rb +2 -1
- data/lib/deep_cover/cli/deep_cover.rb +0 -1
- data/lib/deep_cover/cli/instrumented_clone_reporter.rb +1 -1
- data/lib/deep_cover/load.rb +14 -1
- data/lib/deep_cover/node/base.rb +0 -1
- data/lib/deep_cover/node/mixin/execution_location.rb +1 -1
- data/lib/deep_cover/reporter/html/source.rb +2 -2
- data/lib/deep_cover/tools/profiling.rb +2 -0
- data/lib/deep_cover/version.rb +1 -1
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 024e012ca37ed9e71ea4ddc486bcf410ee68eeba
|
4
|
+
data.tar.gz: 4f9720b0dbb3eda048afbf23339c3875269bd41c
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 07aea48af070f21355740b8821a72ecc78bf7d0bc1ffb8cfd7ec3bbc3994be192a05d4951939e093d66ad22106b5e9125b9e94a17a74399a491e214945567c16
|
7
|
+
data.tar.gz: 051e76cd09f21433a9336baf53f34f111a2a3951f68d0aa04fb3fc76be2ed4b11055609d891faa9e042722c6bcede904dd103272e26719e22e71f44f658398b9
|
data/Gemfile
CHANGED
@@ -7,6 +7,6 @@ git_source(:github) { |repo_name| "https://github.com/#{repo_name}" }
|
|
7
7
|
# Specify your gem's dependencies in deep_cover.gemspec
|
8
8
|
gemspec
|
9
9
|
|
10
|
-
eval_gemfile 'Gemfile.local' if File.exist?('Gemfile.local')
|
10
|
+
eval_gemfile File.expand_path('Gemfile.local', __dir__) if File.exist?('Gemfile.local')
|
11
11
|
|
12
12
|
gem 'ruby-prof', platforms: :mri
|
data/lib/deep_cover/auto_run.rb
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
# frozen_string_literal: true
|
2
2
|
|
3
3
|
module DeepCover
|
4
|
-
|
4
|
+
require_relative '../../deep_cover'
|
5
5
|
bootstrap
|
6
6
|
|
7
7
|
module CLI
|
@@ -84,6 +84,7 @@ module DeepCover
|
|
84
84
|
def pry
|
85
85
|
a = covered_code.covered_ast
|
86
86
|
b = a.children.first
|
87
|
+
::DeepCover.load_pry
|
87
88
|
binding.pry
|
88
89
|
end
|
89
90
|
|
data/lib/deep_cover/load.rb
CHANGED
@@ -20,7 +20,6 @@ module DeepCover
|
|
20
20
|
Object.autoload :Term, 'term/ansicolor'
|
21
21
|
Object.autoload :Terminal, 'terminal-table'
|
22
22
|
Object.autoload :YAML, 'yaml'
|
23
|
-
require 'pry'
|
24
23
|
end
|
25
24
|
|
26
25
|
def bootstrap
|
@@ -41,6 +40,20 @@ module DeepCover
|
|
41
40
|
@parser_loaded
|
42
41
|
end
|
43
42
|
|
43
|
+
def load_pry
|
44
|
+
# I don't know why I have to call these to avoid getting an error:
|
45
|
+
# "WARN: Unresolved specs during Gem::Specification.reset"
|
46
|
+
gem 'binding_of_caller'
|
47
|
+
gem 'highline'
|
48
|
+
gem 'unicode-display_width'
|
49
|
+
gem 'backports'
|
50
|
+
gem 'ruby-progressbar'
|
51
|
+
gem 'tins'
|
52
|
+
gem 'ast'
|
53
|
+
#
|
54
|
+
require 'pry'
|
55
|
+
end
|
56
|
+
|
44
57
|
def load_all
|
45
58
|
return if @all_loaded
|
46
59
|
bootstrap
|
data/lib/deep_cover/node/base.rb
CHANGED
@@ -59,7 +59,7 @@ module DeepCover
|
|
59
59
|
# Returns an array of character numbers (in the original buffer) that
|
60
60
|
# pertain exclusively to this node (and thus not to any children).
|
61
61
|
def proper_range
|
62
|
-
executed_locs.map(&:to_a).inject([], :+).uniq
|
62
|
+
executed_locs.map(&:to_a).inject([], :+).uniq
|
63
63
|
end
|
64
64
|
end
|
65
65
|
end
|
@@ -111,13 +111,13 @@ module DeepCover
|
|
111
111
|
end
|
112
112
|
|
113
113
|
def replace(range, with)
|
114
|
-
@rewriter.replace(range, with)
|
114
|
+
@rewriter.replace(range, with)
|
115
115
|
end
|
116
116
|
|
117
117
|
def wrap(range, before, after = '</span>')
|
118
118
|
line = @rewriter.source_buffer.line_range(range.first_line)
|
119
119
|
pinned = range.with(end_pos: [range, line].map(&:end_pos).min)
|
120
|
-
@rewriter.wrap(pinned, before, after)
|
120
|
+
@rewriter.wrap(pinned, before, after)
|
121
121
|
end
|
122
122
|
|
123
123
|
def html_escape
|
data/lib/deep_cover/version.rb
CHANGED
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.5.
|
4
|
+
version: 0.5.1
|
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: 2018-02-
|
12
|
+
date: 2018-02-11 00:00:00.000000000 Z
|
13
13
|
dependencies:
|
14
14
|
- !ruby/object:Gem::Dependency
|
15
15
|
name: parser
|