coverband 4.0.1 → 4.2.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +5 -5
- data/.gitignore +6 -1
- data/.travis.yml +8 -2
- data/Gemfile +2 -0
- data/Gemfile.rails4 +2 -0
- data/README.md +135 -157
- data/Rakefile +1 -1
- data/changes.md +56 -5
- data/coverband.gemspec +5 -3
- data/lib/coverband/adapters/base.rb +44 -11
- data/lib/coverband/adapters/file_store.rb +8 -0
- data/lib/coverband/adapters/redis_store.rb +65 -8
- data/lib/coverband/at_exit.rb +37 -0
- data/lib/coverband/collectors/coverage.rb +43 -72
- data/lib/coverband/collectors/delta.rb +67 -0
- data/lib/coverband/configuration.rb +71 -2
- data/lib/coverband/integrations/background.rb +9 -10
- data/lib/coverband/integrations/middleware.rb +3 -2
- data/lib/coverband/integrations/rack_server_check.rb +4 -1
- data/lib/coverband/integrations/resque.rb +27 -0
- data/lib/coverband/reporters/base.rb +24 -36
- data/lib/coverband/reporters/html_report.rb +40 -15
- data/lib/coverband/reporters/web.rb +52 -10
- data/lib/coverband/utils/file_groups.rb +53 -0
- data/lib/coverband/utils/file_path_helper.rb +57 -0
- data/lib/coverband/utils/gem_list.rb +31 -0
- data/lib/coverband/utils/html_formatter.rb +50 -8
- data/lib/coverband/utils/railtie.rb +9 -1
- data/lib/coverband/utils/result.rb +16 -19
- data/lib/coverband/utils/results.rb +63 -0
- data/lib/coverband/utils/source_file.rb +23 -1
- data/lib/coverband/utils/tasks.rb +17 -17
- data/lib/coverband/version.rb +1 -1
- data/lib/coverband.rb +32 -2
- data/public/application.css +5 -0
- data/public/application.js +117 -1640
- data/public/dependencies.js +1581 -0
- data/public/favicon.png +0 -0
- data/test/benchmarks/benchmark.rake +36 -1
- data/test/benchmarks/coverage_fork.sh +37 -0
- data/test/{unit/adapters_base_test.rb → coverband/adapters/base_test.rb} +1 -1
- data/test/{unit/adapters_file_store_test.rb → coverband/adapters/file_store_test.rb} +1 -1
- data/test/{unit/adapters_redis_store_test.rb → coverband/adapters/redis_store_test.rb} +28 -11
- data/test/coverband/at_exit_test.rb +13 -0
- data/test/coverband/collectors/coverage_test.rb +73 -0
- data/test/coverband/collectors/delta_test.rb +52 -0
- data/test/coverband/configuration_test.rb +67 -0
- data/test/{unit → coverband}/coverband_test.rb +7 -0
- data/test/coverband/integrations/background_test.rb +31 -0
- data/test/{unit → coverband/integrations}/middleware_test.rb +3 -2
- data/test/{unit/rack_server_checkout_test.rb → coverband/integrations/rack_server_check_test.rb} +1 -1
- data/test/coverband/integrations/resque_worker_test.rb +42 -0
- data/test/coverband/integrations/test_resque_job.rb +7 -0
- data/test/coverband/reporters/base_test.rb +168 -0
- data/test/{unit/reports_console_test.rb → coverband/reporters/console_test.rb} +8 -7
- data/test/coverband/reporters/html_test.rb +45 -0
- data/test/coverband/reporters/web_test.rb +52 -0
- data/test/coverband/utils/file_groups_test.rb +55 -0
- data/test/{unit → coverband}/utils/file_list_test.rb +1 -1
- data/test/coverband/utils/gem_list_test.rb +48 -0
- data/test/{unit → coverband}/utils/source_file_test.rb +1 -1
- data/test/{unit → integration}/full_stack_test.rb +25 -12
- data/test/{unit → integration}/rails_full_stack_test.rb +27 -7
- data/test/rails4_dummy/config/application.rb +1 -1
- data/test/rails4_dummy/config/coverband.rb +4 -1
- data/test/rails4_dummy/tmp/.keep +0 -0
- data/test/rails5_dummy/config/application.rb +1 -1
- data/test/rails5_dummy/config/coverband.rb +3 -1
- data/test/rails5_dummy/tmp/.keep +0 -0
- data/test/rails_test_helper.rb +13 -8
- data/test/test_helper.rb +12 -17
- data/test/unique_files.rb +23 -0
- data/views/file_list.erb +33 -20
- data/views/gem_list.erb +54 -0
- data/views/layout.erb +13 -4
- data/views/settings.erb +35 -0
- data/views/source_file.erb +16 -4
- data/views/source_file_loader.erb +7 -0
- metadata +108 -62
- data/test/unit/background_test.rb +0 -29
- data/test/unit/collectors_coverage_test.rb +0 -48
- data/test/unit/configuration_test.rb +0 -23
- data/test/unit/reports_base_test.rb +0 -109
- data/test/unit/reports_html_test.rb +0 -29
- data/test/unit/reports_web_test.rb +0 -39
- /data/test/{unit → coverband}/utils/lines_classifier_test.rb +0 -0
- /data/test/{unit → coverband}/utils/result_test.rb +0 -0
- /data/test/{unit → coverband}/utils/s3_report_test.rb +0 -0
- /data/test/{unit → coverband}/utils/source_file_line_test.rb +0 -0
- /data/test/{unit/dog.rb → dog.rb} +0 -0
data/test/test_helper.rb
CHANGED
|
@@ -14,21 +14,20 @@ require 'mocha/minitest'
|
|
|
14
14
|
require 'ostruct'
|
|
15
15
|
require 'json'
|
|
16
16
|
require 'redis'
|
|
17
|
+
require 'resque'
|
|
17
18
|
require 'pry-byebug'
|
|
19
|
+
require_relative 'unique_files'
|
|
18
20
|
$VERBOSE = original_verbosity
|
|
19
21
|
|
|
20
22
|
Coveralls.wear!
|
|
21
23
|
|
|
22
|
-
SimpleCov.start do
|
|
23
|
-
add_filter 'specs/ruby/1.9.1/gems/'
|
|
24
|
-
add_filter '/test/'
|
|
25
|
-
add_filter '/config/'
|
|
26
|
-
end
|
|
27
|
-
|
|
28
24
|
module Coverband
|
|
29
25
|
module Test
|
|
30
26
|
def self.reset
|
|
31
|
-
|
|
27
|
+
[:eager_loading, nil].each do |type|
|
|
28
|
+
Coverband.configuration.store.type = type
|
|
29
|
+
Coverband.configuration.store.clear!
|
|
30
|
+
end
|
|
32
31
|
Coverband.configuration.reset
|
|
33
32
|
Coverband::Collectors::Coverage.instance.reset_instance
|
|
34
33
|
Coverband::Background.stop
|
|
@@ -84,20 +83,16 @@ def basic_coverage
|
|
|
84
83
|
{ 'app_path/dog.rb' => example_line }
|
|
85
84
|
end
|
|
86
85
|
|
|
87
|
-
def
|
|
88
|
-
|
|
89
|
-
redis = OpenStruct.new
|
|
90
|
-
redis
|
|
91
|
-
end
|
|
86
|
+
def source_fixture(filename)
|
|
87
|
+
File.expand_path(File.join(File.dirname(__FILE__), 'fixtures', filename))
|
|
92
88
|
end
|
|
93
89
|
|
|
94
|
-
def
|
|
95
|
-
|
|
96
|
-
{ file_name => [1, nil, 1, 1, nil, nil, nil] }
|
|
90
|
+
def test_root
|
|
91
|
+
File.expand_path(File.join(File.dirname(__FILE__)))
|
|
97
92
|
end
|
|
98
93
|
|
|
99
|
-
def
|
|
100
|
-
|
|
94
|
+
def store
|
|
95
|
+
Coverband.configuration.store
|
|
101
96
|
end
|
|
102
97
|
|
|
103
98
|
# Taken from http://stackoverflow.com/questions/4459330/how-do-i-temporarily-redirect-stderr-in-ruby
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
# frozen_string_literal: true
|
|
2
|
+
|
|
3
|
+
require 'securerandom'
|
|
4
|
+
require 'fileutils'
|
|
5
|
+
|
|
6
|
+
UNIQUE_FILES_DIR = "./test/unique_files"
|
|
7
|
+
|
|
8
|
+
def require_unique_file(file = 'dog.rb')
|
|
9
|
+
dir = "#{UNIQUE_FILES_DIR}/#{SecureRandom.uuid}"
|
|
10
|
+
FileUtils.mkdir_p(dir)
|
|
11
|
+
temp_file = "#{dir}/#{file}"
|
|
12
|
+
File.open(temp_file, 'w'){ |w| w.write(File.read("./test/#{file}")) }
|
|
13
|
+
require temp_file
|
|
14
|
+
temp_file
|
|
15
|
+
end
|
|
16
|
+
|
|
17
|
+
def remove_unique_files
|
|
18
|
+
FileUtils.rm_r(UNIQUE_FILES_DIR) if File.exist?(UNIQUE_FILES_DIR)
|
|
19
|
+
end
|
|
20
|
+
|
|
21
|
+
Minitest.after_run do
|
|
22
|
+
remove_unique_files
|
|
23
|
+
end
|
data/views/file_list.erb
CHANGED
|
@@ -1,18 +1,20 @@
|
|
|
1
1
|
<div class="file_list_container" id="<%= title_id %>">
|
|
2
|
-
|
|
3
|
-
<
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
<span class="
|
|
8
|
-
<%= source_files.covered_strength
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
2
|
+
<% unless options[:skip_nav] %>
|
|
3
|
+
<h2>
|
|
4
|
+
<span class="group_name"><%= title %></span>
|
|
5
|
+
(<span class="covered_percent"><span class="<%= coverage_css_class(source_files.covered_percent) %>"><%= source_files.covered_percent.round(2) %>%</span></span>
|
|
6
|
+
covered at
|
|
7
|
+
<span class="covered_strength">
|
|
8
|
+
<span class="<%= strength_css_class(source_files.covered_strength) %>">
|
|
9
|
+
<%= source_files.covered_strength.round(2) %>
|
|
10
|
+
</span>
|
|
11
|
+
</span> hits/line)
|
|
12
|
+
</h2>
|
|
13
|
+
<% end %>
|
|
12
14
|
<a name="<%= title_id %>"></a>
|
|
13
15
|
<div>
|
|
14
16
|
<b><%= source_files.length %></b> files in total.
|
|
15
|
-
<b><%= source_files.lines_of_code %></b> relevant lines.
|
|
17
|
+
<b><%= source_files.lines_of_code %></b> relevant lines.
|
|
16
18
|
<span class="green"><b><%= source_files.covered_lines %></b> lines covered</span> and
|
|
17
19
|
<span class="red"><b><%= source_files.missed_lines %></b> lines missed </span>
|
|
18
20
|
</div>
|
|
@@ -21,24 +23,35 @@
|
|
|
21
23
|
<tr>
|
|
22
24
|
<th>File</th>
|
|
23
25
|
<th>% covered</th>
|
|
26
|
+
<th>% runtime</th>
|
|
24
27
|
<th>Lines</th>
|
|
25
28
|
<th>Relevant Lines</th>
|
|
26
29
|
<th>Lines covered</th>
|
|
30
|
+
<th>Lines runtime</th>
|
|
27
31
|
<th>Lines missed</th>
|
|
28
32
|
<th>Avg. Hits / Line</th>
|
|
29
33
|
</tr>
|
|
30
34
|
</thead>
|
|
31
35
|
<tbody>
|
|
32
36
|
<% source_files.each do |source_file| %>
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
37
|
+
<tr>
|
|
38
|
+
<td class="strong">
|
|
39
|
+
<%= link_to_source_file(source_file) %>
|
|
40
|
+
</td>
|
|
41
|
+
<td class="<%= coverage_css_class(source_file.covered_percent) %> strong"><%= source_file.covered_percent.round(2).to_s %> %</td>
|
|
42
|
+
<% runtime_percentage = result.file_with_type(source_file, Coverband::RUNTIME_TYPE).try(:covered_percent).try(:round, 2) %>
|
|
43
|
+
<td class="<%= "#{coverage_css_class(runtime_percentage)}" %> strong">
|
|
44
|
+
<%= "#{runtime_percentage || '0'} %" %>
|
|
45
|
+
</td>
|
|
46
|
+
<td><%= source_file.lines.count %></td>
|
|
47
|
+
<td><%= source_file.covered_lines.count + source_file.missed_lines.count %></td>
|
|
48
|
+
<td><%= source_file.covered_lines.count %></td>
|
|
49
|
+
<td>
|
|
50
|
+
<%= result.file_with_type(source_file, Coverband::RUNTIME_TYPE).try(:covered_lines).try(:count) || 0 %>
|
|
51
|
+
</td>
|
|
52
|
+
<td><%= source_file.missed_lines.count %></td>
|
|
53
|
+
<td><%= source_file.covered_strength %></td>
|
|
54
|
+
</tr>
|
|
42
55
|
<% end %>
|
|
43
56
|
</tbody>
|
|
44
57
|
</table>
|
data/views/gem_list.erb
ADDED
|
@@ -0,0 +1,54 @@
|
|
|
1
|
+
<div class="file_list_container" id="<%= title_id %>">
|
|
2
|
+
<h2>
|
|
3
|
+
<span class="group_name"><%= title %></span>
|
|
4
|
+
(<span class="covered_percent"><span class="<%= coverage_css_class(source_files.covered_percent) %>"><%= source_files.covered_percent.round(2) %>%</span></span>
|
|
5
|
+
covered at
|
|
6
|
+
<span class="covered_strength">
|
|
7
|
+
<span class="<%= strength_css_class(source_files.covered_strength) %>">
|
|
8
|
+
<%= source_files.covered_strength.round(2) %>
|
|
9
|
+
</span>
|
|
10
|
+
</span> hits/line)
|
|
11
|
+
</h2>
|
|
12
|
+
<div>
|
|
13
|
+
<b><%= source_files.length %></b> files in total.
|
|
14
|
+
<b><%= source_files.lines_of_code %></b> relevant lines.
|
|
15
|
+
<span class="green"><b><%= source_files.covered_lines %></b> lines covered</span> and
|
|
16
|
+
<span class="red"><b><%= source_files.missed_lines %></b> lines missed </span>
|
|
17
|
+
</div>
|
|
18
|
+
<table class="gem_list">
|
|
19
|
+
<thead>
|
|
20
|
+
<tr>
|
|
21
|
+
<th>Gem</th>
|
|
22
|
+
<th>% covered</th>
|
|
23
|
+
<th>Relevant Lines</th>
|
|
24
|
+
<th>Lines covered</th>
|
|
25
|
+
<th>Lines missed</th>
|
|
26
|
+
<th>Avg. Hits / Line</th>
|
|
27
|
+
</tr>
|
|
28
|
+
</thead>
|
|
29
|
+
<tbody>
|
|
30
|
+
<% source_files.each do |source_file| %>
|
|
31
|
+
<tr>
|
|
32
|
+
<td class="strong">
|
|
33
|
+
<% if gem_details? %>
|
|
34
|
+
<%= link_to_gem_list(source_file.first.gem_name) %>
|
|
35
|
+
<% else %>
|
|
36
|
+
<%= source_file.first.gem_name %>
|
|
37
|
+
<% end %>
|
|
38
|
+
</td>
|
|
39
|
+
<td class="<%= coverage_css_class(source_file.covered_percent) %> strong"><%= source_file.covered_percent.round(2).to_s %> %</td>
|
|
40
|
+
<td><%= source_file.covered_lines + source_file.missed_lines %></td>
|
|
41
|
+
<td><%= source_file.covered_lines %></td>
|
|
42
|
+
<td><%= source_file.missed_lines %></td>
|
|
43
|
+
<td><%= source_file.covered_strength %></td>
|
|
44
|
+
</tr>
|
|
45
|
+
<% end %>
|
|
46
|
+
</tbody>
|
|
47
|
+
</table>
|
|
48
|
+
</div>
|
|
49
|
+
|
|
50
|
+
<% if gem_details? %>
|
|
51
|
+
<% source_files.each do |gem_files| %>
|
|
52
|
+
<%= formatted_file_list(gem_files.first.gem_name, result, gem_files, skip_nav: true) %>
|
|
53
|
+
<% end %>
|
|
54
|
+
<% end %>
|
data/views/layout.erb
CHANGED
|
@@ -3,6 +3,7 @@
|
|
|
3
3
|
<head>
|
|
4
4
|
<title>Coverband: <%= Coverband::VERSION %></title>
|
|
5
5
|
<meta http-equiv="content-type" content="text/html; charset=utf-8" />
|
|
6
|
+
<script src='<%= assets_path('dependencies.js') %>' type='text/javascript'></script>
|
|
6
7
|
<script src='<%= assets_path('application.js') %>' type='text/javascript'></script>
|
|
7
8
|
<link href='<%= assets_path('application.css') %>' media='screen, projection, print' rel='stylesheet' type='text/css'>
|
|
8
9
|
<link rel="shortcut icon" type="image/png" href="<%= assets_path("favicon_#{coverage_css_class(result.source_files.covered_percent)}.png") %>" />
|
|
@@ -16,9 +17,15 @@
|
|
|
16
17
|
<div id="wrapper" style="display:none;">
|
|
17
18
|
<div id="header">
|
|
18
19
|
<a href='<%= base_path %>'>Coverband Admin</a>
|
|
20
|
+
<a href='<%= base_path %>settings'>Info</a>
|
|
19
21
|
<%= button("#{base_path}collect_coverage", 'force coverage collection') %>
|
|
20
22
|
<%= button("#{base_path}reload_files", 'reload Coverband files') %>
|
|
21
|
-
|
|
23
|
+
<% if Coverband.configuration.web_enable_clear %>
|
|
24
|
+
<%= button("#{base_path}clear", 'clear coverage report', delete: true) %>
|
|
25
|
+
<% end %>
|
|
26
|
+
<% if Coverband.configuration.web_debug %>
|
|
27
|
+
<a href='<%= base_path %>debug_data'>Debug Data</a>
|
|
28
|
+
<% end %>
|
|
22
29
|
</div>
|
|
23
30
|
<% if notice.to_s.length > 0 %>
|
|
24
31
|
<div class="notice"><%= notice %></div>
|
|
@@ -27,10 +34,10 @@
|
|
|
27
34
|
<ul class="group_tabs"></ul>
|
|
28
35
|
|
|
29
36
|
<div id="content">
|
|
30
|
-
<%= formatted_file_list("All Files", result.source_files) %>
|
|
37
|
+
<%= formatted_file_list("All Files", result, result.source_files) unless view_gems? %>
|
|
31
38
|
|
|
32
39
|
<% result.groups.each do |name, files| %>
|
|
33
|
-
<%= formatted_file_list(name, files) %>
|
|
40
|
+
<%= formatted_file_list(name, result, files) %>
|
|
34
41
|
<% end %>
|
|
35
42
|
</div>
|
|
36
43
|
|
|
@@ -40,7 +47,9 @@
|
|
|
40
47
|
|
|
41
48
|
<div class="source_files">
|
|
42
49
|
<% result.source_files.each do |source_file| %>
|
|
43
|
-
|
|
50
|
+
<% if (!source_file.gem? || (view_gems? && gem_details? && source_file.gem? )) %>
|
|
51
|
+
<%= formatted_source_file_loader(result, source_file) %>
|
|
52
|
+
<% end %>
|
|
44
53
|
<% end %>
|
|
45
54
|
</div>
|
|
46
55
|
</div>
|
data/views/settings.erb
ADDED
|
@@ -0,0 +1,35 @@
|
|
|
1
|
+
<!DOCTYPE html>
|
|
2
|
+
<html xmlns='http://www.w3.org/1999/xhtml'>
|
|
3
|
+
<head>
|
|
4
|
+
<title>Coverband Info: <%= Coverband::VERSION %></title>
|
|
5
|
+
<meta http-equiv="content-type" content="text/html; charset=utf-8" />
|
|
6
|
+
<script src='<%= assets_path('application.js') %>' type='text/javascript'></script>
|
|
7
|
+
<link href='<%= assets_path('application.css') %>' media='screen, projection, print' rel='stylesheet' type='text/css'>
|
|
8
|
+
<link rel="icon" type="image/png" href="<%= assets_path('favicon.png') %>" />
|
|
9
|
+
</head>
|
|
10
|
+
|
|
11
|
+
<body>
|
|
12
|
+
<div id="wrapper" style="">
|
|
13
|
+
<div id="header">
|
|
14
|
+
<a href='<%= base_path %>'>Coverband Admin</a>
|
|
15
|
+
<a href='<%= base_path %>settings'>Info</a>
|
|
16
|
+
</div>
|
|
17
|
+
<div id="content">
|
|
18
|
+
<dl>
|
|
19
|
+
<% Coverband.configuration.to_h.each_pair do |key,value| %>
|
|
20
|
+
<dt><%= key %></dt>
|
|
21
|
+
<dd><%= value %></dd>
|
|
22
|
+
<% end %>
|
|
23
|
+
|
|
24
|
+
<dt>Size (in bytes)</dt>
|
|
25
|
+
<dd><%= Coverband.configuration.store.size %></dd>
|
|
26
|
+
<dt>Size (in MiB)</dt>
|
|
27
|
+
<dd><%= Coverband.configuration.store.size_in_mib %></dd>
|
|
28
|
+
</dl>
|
|
29
|
+
</div>
|
|
30
|
+
<div id="footer">
|
|
31
|
+
Generated by <a href="http://github.com/danmayer/coverband">Coverband</a> v<%= Coverband::VERSION %>
|
|
32
|
+
</div>
|
|
33
|
+
</div>
|
|
34
|
+
</body>
|
|
35
|
+
</html>
|
data/views/source_file.erb
CHANGED
|
@@ -1,23 +1,35 @@
|
|
|
1
1
|
<div class="source_table" id="<%= id source_file %>">
|
|
2
2
|
<div class="header">
|
|
3
3
|
<h3><%= shortened_filename source_file %></h3>
|
|
4
|
-
<h4
|
|
4
|
+
<h4>
|
|
5
|
+
<span class="<%= coverage_css_class(source_file.covered_percent) %>"><%= source_file.covered_percent.round(2).to_s %> %</span>
|
|
6
|
+
covered
|
|
7
|
+
<% if Coverband.configuration.web_enable_clear %>
|
|
8
|
+
<%= button("#{base_path}clear_file?filename=#{source_file.relative_path}", 'clear file coverage') %>
|
|
9
|
+
<% end %>
|
|
10
|
+
</h4>
|
|
5
11
|
<div>
|
|
6
12
|
<b><%= source_file.lines_of_code %></b> relevant lines.
|
|
7
13
|
<span class="green"><b><%= source_file.covered_lines.count %></b> lines covered</span> and
|
|
8
14
|
<span class="red"><b><%= source_file.missed_lines.count %></b> lines missed.</span>
|
|
9
15
|
</div>
|
|
10
16
|
<div>
|
|
11
|
-
Coverage first seen: <%= source_file.first_updated_at %>, last activity recorded:
|
|
17
|
+
Coverage first seen: <%= source_file.first_updated_at %>, last activity recorded:
|
|
12
18
|
<%= source_file.last_updated_at %>
|
|
13
19
|
</div>
|
|
14
20
|
</div>
|
|
15
21
|
|
|
16
22
|
<pre>
|
|
17
23
|
<ol>
|
|
18
|
-
<% source_file.lines.
|
|
24
|
+
<% source_file.lines.each_with_index do |line, index| %>
|
|
19
25
|
<li class="<%= line.status %>" data-hits="<%= line.coverage ? line.coverage : '' %>" data-linenumber="<%= line.number %>">
|
|
20
|
-
<% if line.covered? %><span class="hits"
|
|
26
|
+
<% if line.covered? %><span class="hits">
|
|
27
|
+
load:
|
|
28
|
+
<%= result.file_with_type(source_file, Coverband::EAGER_TYPE).try(:lines).try(:[], index).try(:coverage) || 0 %>,
|
|
29
|
+
runtime:
|
|
30
|
+
<%= result.file_with_type(source_file, Coverband::RUNTIME_TYPE).try(:lines).try(:[], index).try(:coverage) || 0 %>
|
|
31
|
+
all: <%= line.coverage %>
|
|
32
|
+
</span><% end %>
|
|
21
33
|
<% if line.skipped? %><span class="hits">skipped</span><% end %>
|
|
22
34
|
<code class="ruby"><%= CGI.escapeHTML(line.src.chomp) %></code>
|
|
23
35
|
</li>
|
metadata
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
|
2
2
|
name: coverband
|
|
3
3
|
version: !ruby/object:Gem::Version
|
|
4
|
-
version: 4.0
|
|
4
|
+
version: 4.2.0
|
|
5
5
|
platform: ruby
|
|
6
6
|
authors:
|
|
7
7
|
- Dan Mayer
|
|
@@ -9,7 +9,7 @@ authors:
|
|
|
9
9
|
autorequire:
|
|
10
10
|
bindir: bin
|
|
11
11
|
cert_chain: []
|
|
12
|
-
date:
|
|
12
|
+
date: 2019-04-24 00:00:00.000000000 Z
|
|
13
13
|
dependencies:
|
|
14
14
|
- !ruby/object:Gem::Dependency
|
|
15
15
|
name: aws-sdk-s3
|
|
@@ -39,20 +39,6 @@ dependencies:
|
|
|
39
39
|
- - ">="
|
|
40
40
|
- !ruby/object:Gem::Version
|
|
41
41
|
version: '0'
|
|
42
|
-
- !ruby/object:Gem::Dependency
|
|
43
|
-
name: bundler
|
|
44
|
-
requirement: !ruby/object:Gem::Requirement
|
|
45
|
-
requirements:
|
|
46
|
-
- - "~>"
|
|
47
|
-
- !ruby/object:Gem::Version
|
|
48
|
-
version: '1.3'
|
|
49
|
-
type: :development
|
|
50
|
-
prerelease: false
|
|
51
|
-
version_requirements: !ruby/object:Gem::Requirement
|
|
52
|
-
requirements:
|
|
53
|
-
- - "~>"
|
|
54
|
-
- !ruby/object:Gem::Version
|
|
55
|
-
version: '1.3'
|
|
56
42
|
- !ruby/object:Gem::Dependency
|
|
57
43
|
name: capybara
|
|
58
44
|
requirement: !ruby/object:Gem::Requirement
|
|
@@ -166,7 +152,21 @@ dependencies:
|
|
|
166
152
|
- !ruby/object:Gem::Version
|
|
167
153
|
version: '0'
|
|
168
154
|
- !ruby/object:Gem::Dependency
|
|
169
|
-
name:
|
|
155
|
+
name: resque
|
|
156
|
+
requirement: !ruby/object:Gem::Requirement
|
|
157
|
+
requirements:
|
|
158
|
+
- - ">="
|
|
159
|
+
- !ruby/object:Gem::Version
|
|
160
|
+
version: '0'
|
|
161
|
+
type: :development
|
|
162
|
+
prerelease: false
|
|
163
|
+
version_requirements: !ruby/object:Gem::Requirement
|
|
164
|
+
requirements:
|
|
165
|
+
- - ">="
|
|
166
|
+
- !ruby/object:Gem::Version
|
|
167
|
+
version: '0'
|
|
168
|
+
- !ruby/object:Gem::Dependency
|
|
169
|
+
name: minitest-reporters
|
|
170
170
|
requirement: !ruby/object:Gem::Requirement
|
|
171
171
|
requirements:
|
|
172
172
|
- - ">="
|
|
@@ -221,6 +221,20 @@ dependencies:
|
|
|
221
221
|
- - ">="
|
|
222
222
|
- !ruby/object:Gem::Version
|
|
223
223
|
version: '0'
|
|
224
|
+
- !ruby/object:Gem::Dependency
|
|
225
|
+
name: minitest-profile
|
|
226
|
+
requirement: !ruby/object:Gem::Requirement
|
|
227
|
+
requirements:
|
|
228
|
+
- - ">="
|
|
229
|
+
- !ruby/object:Gem::Version
|
|
230
|
+
version: '0'
|
|
231
|
+
type: :development
|
|
232
|
+
prerelease: false
|
|
233
|
+
version_requirements: !ruby/object:Gem::Requirement
|
|
234
|
+
requirements:
|
|
235
|
+
- - ">="
|
|
236
|
+
- !ruby/object:Gem::Version
|
|
237
|
+
version: '0'
|
|
224
238
|
- !ruby/object:Gem::Dependency
|
|
225
239
|
name: redis
|
|
226
240
|
requirement: !ruby/object:Gem::Requirement
|
|
@@ -258,20 +272,27 @@ files:
|
|
|
258
272
|
- lib/coverband/adapters/base.rb
|
|
259
273
|
- lib/coverband/adapters/file_store.rb
|
|
260
274
|
- lib/coverband/adapters/redis_store.rb
|
|
275
|
+
- lib/coverband/at_exit.rb
|
|
261
276
|
- lib/coverband/collectors/coverage.rb
|
|
277
|
+
- lib/coverband/collectors/delta.rb
|
|
262
278
|
- lib/coverband/configuration.rb
|
|
263
279
|
- lib/coverband/integrations/background.rb
|
|
264
280
|
- lib/coverband/integrations/middleware.rb
|
|
265
281
|
- lib/coverband/integrations/rack_server_check.rb
|
|
282
|
+
- lib/coverband/integrations/resque.rb
|
|
266
283
|
- lib/coverband/reporters/base.rb
|
|
267
284
|
- lib/coverband/reporters/console_report.rb
|
|
268
285
|
- lib/coverband/reporters/html_report.rb
|
|
269
286
|
- lib/coverband/reporters/web.rb
|
|
287
|
+
- lib/coverband/utils/file_groups.rb
|
|
270
288
|
- lib/coverband/utils/file_list.rb
|
|
289
|
+
- lib/coverband/utils/file_path_helper.rb
|
|
290
|
+
- lib/coverband/utils/gem_list.rb
|
|
271
291
|
- lib/coverband/utils/html_formatter.rb
|
|
272
292
|
- lib/coverband/utils/lines_classifier.rb
|
|
273
293
|
- lib/coverband/utils/railtie.rb
|
|
274
294
|
- lib/coverband/utils/result.rb
|
|
295
|
+
- lib/coverband/utils/results.rb
|
|
275
296
|
- lib/coverband/utils/s3_report.rb
|
|
276
297
|
- lib/coverband/utils/source_file.rb
|
|
277
298
|
- lib/coverband/utils/tasks.rb
|
|
@@ -282,6 +303,8 @@ files:
|
|
|
282
303
|
- public/colorbox/controls.png
|
|
283
304
|
- public/colorbox/loading.gif
|
|
284
305
|
- public/colorbox/loading_background.png
|
|
306
|
+
- public/dependencies.js
|
|
307
|
+
- public/favicon.png
|
|
285
308
|
- public/favicon_green.png
|
|
286
309
|
- public/favicon_red.png
|
|
287
310
|
- public/favicon_yellow.png
|
|
@@ -302,8 +325,35 @@ files:
|
|
|
302
325
|
- public/magnify.png
|
|
303
326
|
- test/benchmarks/.gitignore
|
|
304
327
|
- test/benchmarks/benchmark.rake
|
|
328
|
+
- test/benchmarks/coverage_fork.sh
|
|
305
329
|
- test/benchmarks/dog.rb
|
|
306
330
|
- test/benchmarks/graph_bench.sh
|
|
331
|
+
- test/coverband/adapters/base_test.rb
|
|
332
|
+
- test/coverband/adapters/file_store_test.rb
|
|
333
|
+
- test/coverband/adapters/redis_store_test.rb
|
|
334
|
+
- test/coverband/at_exit_test.rb
|
|
335
|
+
- test/coverband/collectors/coverage_test.rb
|
|
336
|
+
- test/coverband/collectors/delta_test.rb
|
|
337
|
+
- test/coverband/configuration_test.rb
|
|
338
|
+
- test/coverband/coverband_test.rb
|
|
339
|
+
- test/coverband/integrations/background_test.rb
|
|
340
|
+
- test/coverband/integrations/middleware_test.rb
|
|
341
|
+
- test/coverband/integrations/rack_server_check_test.rb
|
|
342
|
+
- test/coverband/integrations/resque_worker_test.rb
|
|
343
|
+
- test/coverband/integrations/test_resque_job.rb
|
|
344
|
+
- test/coverband/reporters/base_test.rb
|
|
345
|
+
- test/coverband/reporters/console_test.rb
|
|
346
|
+
- test/coverband/reporters/html_test.rb
|
|
347
|
+
- test/coverband/reporters/web_test.rb
|
|
348
|
+
- test/coverband/utils/file_groups_test.rb
|
|
349
|
+
- test/coverband/utils/file_list_test.rb
|
|
350
|
+
- test/coverband/utils/gem_list_test.rb
|
|
351
|
+
- test/coverband/utils/lines_classifier_test.rb
|
|
352
|
+
- test/coverband/utils/result_test.rb
|
|
353
|
+
- test/coverband/utils/s3_report_test.rb
|
|
354
|
+
- test/coverband/utils/source_file_line_test.rb
|
|
355
|
+
- test/coverband/utils/source_file_test.rb
|
|
356
|
+
- test/dog.rb
|
|
307
357
|
- test/fake_app/basic_rack.rb
|
|
308
358
|
- test/fixtures/app/controllers/sample_controller.rb
|
|
309
359
|
- test/fixtures/app/models/user.rb
|
|
@@ -312,6 +362,8 @@ files:
|
|
|
312
362
|
- test/fixtures/skipped.rb
|
|
313
363
|
- test/fixtures/skipped_and_executed.rb
|
|
314
364
|
- test/fixtures/utf-8.rb
|
|
365
|
+
- test/integration/full_stack_test.rb
|
|
366
|
+
- test/integration/rails_full_stack_test.rb
|
|
315
367
|
- test/rails4_dummy/app/controllers/dummy_controller.rb
|
|
316
368
|
- test/rails4_dummy/config.ru
|
|
317
369
|
- test/rails4_dummy/config/application.rb
|
|
@@ -320,39 +372,23 @@ files:
|
|
|
320
372
|
- test/rails4_dummy/config/environment.rb
|
|
321
373
|
- test/rails4_dummy/config/routes.rb
|
|
322
374
|
- test/rails4_dummy/config/secrets.yml
|
|
375
|
+
- test/rails4_dummy/tmp/.keep
|
|
323
376
|
- test/rails5_dummy/app/controllers/dummy_controller.rb
|
|
324
377
|
- test/rails5_dummy/config.ru
|
|
325
378
|
- test/rails5_dummy/config/application.rb
|
|
326
379
|
- test/rails5_dummy/config/coverband.rb
|
|
327
380
|
- test/rails5_dummy/config/environment.rb
|
|
328
381
|
- test/rails5_dummy/config/routes.rb
|
|
382
|
+
- test/rails5_dummy/tmp/.keep
|
|
329
383
|
- test/rails_test_helper.rb
|
|
330
384
|
- test/test_helper.rb
|
|
331
|
-
- test/
|
|
332
|
-
- test/unit/adapters_file_store_test.rb
|
|
333
|
-
- test/unit/adapters_redis_store_test.rb
|
|
334
|
-
- test/unit/background_test.rb
|
|
335
|
-
- test/unit/collectors_coverage_test.rb
|
|
336
|
-
- test/unit/configuration_test.rb
|
|
337
|
-
- test/unit/coverband_test.rb
|
|
338
|
-
- test/unit/dog.rb
|
|
339
|
-
- test/unit/full_stack_test.rb
|
|
340
|
-
- test/unit/middleware_test.rb
|
|
341
|
-
- test/unit/rack_server_checkout_test.rb
|
|
342
|
-
- test/unit/rails_full_stack_test.rb
|
|
343
|
-
- test/unit/reports_base_test.rb
|
|
344
|
-
- test/unit/reports_console_test.rb
|
|
345
|
-
- test/unit/reports_html_test.rb
|
|
346
|
-
- test/unit/reports_web_test.rb
|
|
347
|
-
- test/unit/utils/file_list_test.rb
|
|
348
|
-
- test/unit/utils/lines_classifier_test.rb
|
|
349
|
-
- test/unit/utils/result_test.rb
|
|
350
|
-
- test/unit/utils/s3_report_test.rb
|
|
351
|
-
- test/unit/utils/source_file_line_test.rb
|
|
352
|
-
- test/unit/utils/source_file_test.rb
|
|
385
|
+
- test/unique_files.rb
|
|
353
386
|
- views/file_list.erb
|
|
387
|
+
- views/gem_list.erb
|
|
354
388
|
- views/layout.erb
|
|
389
|
+
- views/settings.erb
|
|
355
390
|
- views/source_file.erb
|
|
391
|
+
- views/source_file_loader.erb
|
|
356
392
|
homepage: https://github.com/danmayer/coverband
|
|
357
393
|
licenses:
|
|
358
394
|
- MIT
|
|
@@ -373,15 +409,42 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
|
373
409
|
version: '0'
|
|
374
410
|
requirements: []
|
|
375
411
|
rubyforge_project:
|
|
376
|
-
rubygems_version: 2.
|
|
412
|
+
rubygems_version: 2.7.8
|
|
377
413
|
signing_key:
|
|
378
414
|
specification_version: 4
|
|
379
415
|
summary: Rack middleware to help measure production code usage (LOC runtime usage)
|
|
380
416
|
test_files:
|
|
381
417
|
- test/benchmarks/.gitignore
|
|
382
418
|
- test/benchmarks/benchmark.rake
|
|
419
|
+
- test/benchmarks/coverage_fork.sh
|
|
383
420
|
- test/benchmarks/dog.rb
|
|
384
421
|
- test/benchmarks/graph_bench.sh
|
|
422
|
+
- test/coverband/adapters/base_test.rb
|
|
423
|
+
- test/coverband/adapters/file_store_test.rb
|
|
424
|
+
- test/coverband/adapters/redis_store_test.rb
|
|
425
|
+
- test/coverband/at_exit_test.rb
|
|
426
|
+
- test/coverband/collectors/coverage_test.rb
|
|
427
|
+
- test/coverband/collectors/delta_test.rb
|
|
428
|
+
- test/coverband/configuration_test.rb
|
|
429
|
+
- test/coverband/coverband_test.rb
|
|
430
|
+
- test/coverband/integrations/background_test.rb
|
|
431
|
+
- test/coverband/integrations/middleware_test.rb
|
|
432
|
+
- test/coverband/integrations/rack_server_check_test.rb
|
|
433
|
+
- test/coverband/integrations/resque_worker_test.rb
|
|
434
|
+
- test/coverband/integrations/test_resque_job.rb
|
|
435
|
+
- test/coverband/reporters/base_test.rb
|
|
436
|
+
- test/coverband/reporters/console_test.rb
|
|
437
|
+
- test/coverband/reporters/html_test.rb
|
|
438
|
+
- test/coverband/reporters/web_test.rb
|
|
439
|
+
- test/coverband/utils/file_groups_test.rb
|
|
440
|
+
- test/coverband/utils/file_list_test.rb
|
|
441
|
+
- test/coverband/utils/gem_list_test.rb
|
|
442
|
+
- test/coverband/utils/lines_classifier_test.rb
|
|
443
|
+
- test/coverband/utils/result_test.rb
|
|
444
|
+
- test/coverband/utils/s3_report_test.rb
|
|
445
|
+
- test/coverband/utils/source_file_line_test.rb
|
|
446
|
+
- test/coverband/utils/source_file_test.rb
|
|
447
|
+
- test/dog.rb
|
|
385
448
|
- test/fake_app/basic_rack.rb
|
|
386
449
|
- test/fixtures/app/controllers/sample_controller.rb
|
|
387
450
|
- test/fixtures/app/models/user.rb
|
|
@@ -390,6 +453,8 @@ test_files:
|
|
|
390
453
|
- test/fixtures/skipped.rb
|
|
391
454
|
- test/fixtures/skipped_and_executed.rb
|
|
392
455
|
- test/fixtures/utf-8.rb
|
|
456
|
+
- test/integration/full_stack_test.rb
|
|
457
|
+
- test/integration/rails_full_stack_test.rb
|
|
393
458
|
- test/rails4_dummy/app/controllers/dummy_controller.rb
|
|
394
459
|
- test/rails4_dummy/config.ru
|
|
395
460
|
- test/rails4_dummy/config/application.rb
|
|
@@ -398,33 +463,14 @@ test_files:
|
|
|
398
463
|
- test/rails4_dummy/config/environment.rb
|
|
399
464
|
- test/rails4_dummy/config/routes.rb
|
|
400
465
|
- test/rails4_dummy/config/secrets.yml
|
|
466
|
+
- test/rails4_dummy/tmp/.keep
|
|
401
467
|
- test/rails5_dummy/app/controllers/dummy_controller.rb
|
|
402
468
|
- test/rails5_dummy/config.ru
|
|
403
469
|
- test/rails5_dummy/config/application.rb
|
|
404
470
|
- test/rails5_dummy/config/coverband.rb
|
|
405
471
|
- test/rails5_dummy/config/environment.rb
|
|
406
472
|
- test/rails5_dummy/config/routes.rb
|
|
473
|
+
- test/rails5_dummy/tmp/.keep
|
|
407
474
|
- test/rails_test_helper.rb
|
|
408
475
|
- test/test_helper.rb
|
|
409
|
-
- test/
|
|
410
|
-
- test/unit/adapters_file_store_test.rb
|
|
411
|
-
- test/unit/adapters_redis_store_test.rb
|
|
412
|
-
- test/unit/background_test.rb
|
|
413
|
-
- test/unit/collectors_coverage_test.rb
|
|
414
|
-
- test/unit/configuration_test.rb
|
|
415
|
-
- test/unit/coverband_test.rb
|
|
416
|
-
- test/unit/dog.rb
|
|
417
|
-
- test/unit/full_stack_test.rb
|
|
418
|
-
- test/unit/middleware_test.rb
|
|
419
|
-
- test/unit/rack_server_checkout_test.rb
|
|
420
|
-
- test/unit/rails_full_stack_test.rb
|
|
421
|
-
- test/unit/reports_base_test.rb
|
|
422
|
-
- test/unit/reports_console_test.rb
|
|
423
|
-
- test/unit/reports_html_test.rb
|
|
424
|
-
- test/unit/reports_web_test.rb
|
|
425
|
-
- test/unit/utils/file_list_test.rb
|
|
426
|
-
- test/unit/utils/lines_classifier_test.rb
|
|
427
|
-
- test/unit/utils/result_test.rb
|
|
428
|
-
- test/unit/utils/s3_report_test.rb
|
|
429
|
-
- test/unit/utils/source_file_line_test.rb
|
|
430
|
-
- test/unit/utils/source_file_test.rb
|
|
476
|
+
- test/unique_files.rb
|