coco 0.5 → 0.5.1
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.
- data/NEWS +7 -0
- data/README.rdoc +5 -0
- data/Rakefile +4 -4
- data/VERSION +1 -1
- data/lib/coco/configuration.rb +18 -0
- data/lib/coco/writer/html_files_writer.rb +1 -1
- metadata +55 -65
data/NEWS
CHANGED
data/README.rdoc
CHANGED
@@ -4,6 +4,7 @@ Another code coverage for ruby 1.9 (from the famous post of Aaron Patterson).
|
|
4
4
|
|
5
5
|
== Features
|
6
6
|
* Use it from rspec or test/unit with a simple <code>require 'coco'</code>
|
7
|
+
* Works with Rails
|
7
8
|
* Display filenames covered less than 90% on console
|
8
9
|
* <em>Simple</em> html report <em>only</em> for files covered less than 90%
|
9
10
|
* Report sources that have no tests
|
@@ -48,3 +49,7 @@ GPLv3, see COPYING.
|
|
48
49
|
|
49
50
|
Feel free to email {Xavier Nayrac}[mailto:xavier.nayrac@gmail.com]
|
50
51
|
with any questions.
|
52
|
+
|
53
|
+
== Contributors
|
54
|
+
|
55
|
+
{sunaku (Suraj N. Kurapati)}[https://github.com/sunaku]
|
data/Rakefile
CHANGED
@@ -13,7 +13,7 @@ task :default => :spec
|
|
13
13
|
|
14
14
|
desc 'Test coco'
|
15
15
|
RSpec::Core::RakeTask.new(:spec) do |t|
|
16
|
-
t.rspec_opts = ['--color']
|
16
|
+
t.rspec_opts = ['--color --format documentation']
|
17
17
|
end
|
18
18
|
|
19
19
|
desc 'Check for code smells'
|
@@ -33,11 +33,11 @@ end
|
|
33
33
|
desc 'Build the gem & install it'
|
34
34
|
task :install do
|
35
35
|
sh "gem build coco.gemspec"
|
36
|
-
|
37
|
-
|
36
|
+
f = FileList['coco*gem'].to_a
|
37
|
+
sh "gem install #{f.first} --no-rdoc --no-ri"
|
38
38
|
end
|
39
39
|
|
40
40
|
desc 'Generate yard documentation for developpers'
|
41
41
|
task :doc do
|
42
|
-
|
42
|
+
exec 'yardoc --title "Coco Documentation" - NEWS COPYING VERSION'
|
43
43
|
end
|
data/VERSION
CHANGED
@@ -1 +1 @@
|
|
1
|
-
0.5
|
1
|
+
0.5.1
|
data/lib/coco/configuration.rb
CHANGED
@@ -28,6 +28,24 @@ module Coco
|
|
28
28
|
conf = YAML.load_file '.coco'
|
29
29
|
self.merge!(conf)
|
30
30
|
end
|
31
|
+
expand_directories
|
32
|
+
remove_directories
|
33
|
+
end
|
34
|
+
|
35
|
+
private
|
36
|
+
|
37
|
+
def expand_directories
|
38
|
+
self[:excludes].each do |file_or_dir|
|
39
|
+
add_files file_or_dir if File.directory?(file_or_dir)
|
40
|
+
end
|
41
|
+
end
|
42
|
+
|
43
|
+
def add_files dir
|
44
|
+
Helpers.rb_files_from(dir).each {|file| self[:excludes] << file }
|
45
|
+
end
|
46
|
+
|
47
|
+
def remove_directories
|
48
|
+
self[:excludes].delete_if {|file_or_dir| File.directory?(file_or_dir)}
|
31
49
|
end
|
32
50
|
|
33
51
|
end
|
metadata
CHANGED
@@ -1,111 +1,101 @@
|
|
1
|
-
--- !ruby/object:Gem::Specification
|
1
|
+
--- !ruby/object:Gem::Specification
|
2
2
|
name: coco
|
3
|
-
version: !ruby/object:Gem::Version
|
4
|
-
|
5
|
-
|
6
|
-
- 0
|
7
|
-
- 5
|
8
|
-
version: "0.5"
|
3
|
+
version: !ruby/object:Gem::Version
|
4
|
+
version: 0.5.1
|
5
|
+
prerelease:
|
9
6
|
platform: ruby
|
10
|
-
authors:
|
7
|
+
authors:
|
11
8
|
- Xavier Nayrac
|
12
9
|
autorequire:
|
13
10
|
bindir: bin
|
14
11
|
cert_chain: []
|
15
|
-
|
16
|
-
date: 2011-03-14 00:00:00 +01:00
|
12
|
+
date: 2011-08-08 00:00:00.000000000 +02:00
|
17
13
|
default_executable:
|
18
14
|
dependencies: []
|
15
|
+
description: ! '"Another code coverage tool for ruby 1.9
|
19
16
|
|
20
|
-
description: |-
|
21
|
-
"Another code coverage tool for ruby 1.9
|
22
17
|
(from the famous post of Aaron Patterson).
|
23
|
-
|
18
|
+
|
19
|
+
* Simply "require ''coco''" from rspec or unit/test
|
20
|
+
|
24
21
|
* Display filenames covered less than 90% on console
|
22
|
+
|
25
23
|
* Build simple html report only for files covered less than 90%
|
24
|
+
|
26
25
|
* Report sources that have no tests
|
26
|
+
|
27
27
|
* UTF-8 compliant
|
28
|
+
|
28
29
|
* Configurable with a simple yaml file
|
29
|
-
|
30
|
+
|
31
|
+
* Colorized console output (*nix only)'
|
30
32
|
email: xavier.nayrac@gmail.com
|
31
33
|
executables: []
|
32
|
-
|
33
34
|
extensions: []
|
34
|
-
|
35
35
|
extra_rdoc_files: []
|
36
|
-
|
37
|
-
|
38
|
-
- lib/coco/formatter.rb
|
39
|
-
- lib/coco/writer/html_index_writer.rb
|
40
|
-
- lib/coco/writer/file_writer.rb
|
41
|
-
- lib/coco/writer/html_directory.rb
|
42
|
-
- lib/coco/writer/html_files_writer.rb
|
36
|
+
files:
|
37
|
+
- lib/coco.rb
|
43
38
|
- lib/coco/writer.rb
|
44
|
-
- lib/coco/
|
45
|
-
- lib/coco/
|
46
|
-
- lib/coco/
|
47
|
-
- lib/coco/
|
48
|
-
- lib/coco/formatter/context.rb
|
49
|
-
- lib/coco/formatter/template.rb
|
39
|
+
- lib/coco/lister/uncovered_lister.rb
|
40
|
+
- lib/coco/lister/source_lister.rb
|
41
|
+
- lib/coco/lister.rb
|
42
|
+
- lib/coco/configuration.rb
|
50
43
|
- lib/coco/formatter/console_formatter.rb
|
44
|
+
- lib/coco/formatter/template.rb
|
45
|
+
- lib/coco/formatter/context.rb
|
51
46
|
- lib/coco/formatter/colored_string.rb
|
52
|
-
- lib/coco/
|
47
|
+
- lib/coco/formatter/html_index_formatter.rb
|
48
|
+
- lib/coco/formatter/formatter.rb
|
49
|
+
- lib/coco/formatter/html_formatter.rb
|
50
|
+
- lib/coco/cover.rb
|
53
51
|
- lib/coco/helpers.rb
|
54
|
-
- lib/coco/cover/coverage_stat.rb
|
55
52
|
- lib/coco/cover/coverage_result.rb
|
56
|
-
- lib/coco/
|
57
|
-
- lib/coco/
|
58
|
-
- lib/coco/
|
59
|
-
- lib/coco.rb
|
53
|
+
- lib/coco/cover/coverage_stat.rb
|
54
|
+
- lib/coco/writer/file_writer.rb
|
55
|
+
- lib/coco/writer/html_files_writer.rb
|
56
|
+
- lib/coco/writer/html_directory.rb
|
57
|
+
- lib/coco/writer/html_index_writer.rb
|
58
|
+
- lib/coco/formatter.rb
|
59
|
+
- template/file.erb
|
60
60
|
- template/index.erb
|
61
|
-
- template/img/coconut16.png
|
62
|
-
- template/img/licenses
|
63
|
-
- template/css/base-min.css
|
64
|
-
- template/css/ext.css
|
65
|
-
- template/css/reset-min.css
|
66
61
|
- template/css/fonts-min.css
|
62
|
+
- template/css/reset-min.css
|
67
63
|
- template/css/coco.css
|
68
64
|
- template/css/LICENCE
|
69
|
-
- template/
|
70
|
-
-
|
71
|
-
-
|
72
|
-
-
|
65
|
+
- template/css/ext.css
|
66
|
+
- template/css/base-min.css
|
67
|
+
- template/img/licenses
|
68
|
+
- template/img/coconut16.png
|
73
69
|
- VERSION
|
74
70
|
- COPYING
|
71
|
+
- NEWS
|
75
72
|
- Rakefile
|
73
|
+
- TODO
|
74
|
+
- README.rdoc
|
76
75
|
has_rdoc: true
|
77
76
|
homepage: http://lkdjiin.github.com/coco/
|
78
|
-
licenses:
|
77
|
+
licenses:
|
79
78
|
- GPL-3
|
80
79
|
post_install_message:
|
81
80
|
rdoc_options: []
|
82
|
-
|
83
|
-
require_paths:
|
81
|
+
require_paths:
|
84
82
|
- lib
|
85
|
-
required_ruby_version: !ruby/object:Gem::Requirement
|
83
|
+
required_ruby_version: !ruby/object:Gem::Requirement
|
86
84
|
none: false
|
87
|
-
requirements:
|
88
|
-
- -
|
89
|
-
- !ruby/object:Gem::Version
|
90
|
-
segments:
|
91
|
-
- 1
|
92
|
-
- 9
|
93
|
-
- 2
|
85
|
+
requirements:
|
86
|
+
- - ! '>='
|
87
|
+
- !ruby/object:Gem::Version
|
94
88
|
version: 1.9.2
|
95
|
-
required_rubygems_version: !ruby/object:Gem::Requirement
|
89
|
+
required_rubygems_version: !ruby/object:Gem::Requirement
|
96
90
|
none: false
|
97
|
-
requirements:
|
98
|
-
- -
|
99
|
-
- !ruby/object:Gem::Version
|
100
|
-
|
101
|
-
- 0
|
102
|
-
version: "0"
|
91
|
+
requirements:
|
92
|
+
- - ! '>='
|
93
|
+
- !ruby/object:Gem::Version
|
94
|
+
version: '0'
|
103
95
|
requirements: []
|
104
|
-
|
105
96
|
rubyforge_project:
|
106
|
-
rubygems_version: 1.
|
97
|
+
rubygems_version: 1.6.2
|
107
98
|
signing_key:
|
108
99
|
specification_version: 3
|
109
100
|
summary: Code coverage tool for ruby 1.9.
|
110
101
|
test_files: []
|
111
|
-
|