checkm 0.0.1 → 0.0.2

Sign up to get free protection for your applications and to get access to all the features.
data/VERSION CHANGED
@@ -1 +1 @@
1
- 0.0.1
1
+ 0.0.2
@@ -5,7 +5,7 @@
5
5
 
6
6
  Gem::Specification.new do |s|
7
7
  s.name = %q{checkm}
8
- s.version = "0.0.1"
8
+ s.version = "0.0.2"
9
9
 
10
10
  s.required_rubygems_version = Gem::Requirement.new(">= 0") if s.respond_to? :required_rubygems_version=
11
11
  s.authors = ["Chris Beer"]
@@ -49,17 +49,18 @@ module Checkm
49
49
  end
50
50
 
51
51
  def valid?
52
+ return true if @entries.empty?
52
53
  @entries.map { |e| e.valid? }.any? { |b| b == false }
53
54
  end
54
55
 
55
56
  def add path, args = {}
56
57
  line = Checkm::Entry.create path, args
57
58
 
58
- Checkm::Manifest.new [@lines, line].flatten.join("\n"), args
59
+ Checkm::Manifest.new [@lines, line].flatten.join("\n"), @args
59
60
  end
60
61
 
61
62
  def remove path
62
- Checkm::Manifest.new @lines.reject { |x| x =~ /^@?#{path}/ }.join("\n"), args
63
+ Checkm::Manifest.new @lines.reject { |x| x =~ /^@?#{path}/ }.join("\n"), @args
63
64
  end
64
65
 
65
66
  def to_s
@@ -5,6 +5,7 @@ class TestCheckm < Test::Unit::TestCase
5
5
  checkm = ''
6
6
  res = Checkm::Manifest.parse(checkm)
7
7
  assert_equal(res.entries.empty?, true)
8
+ assert_equal(res.valid?, true)
8
9
  end
9
10
 
10
11
  def test_comment
metadata CHANGED
@@ -1,13 +1,13 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: checkm
3
3
  version: !ruby/object:Gem::Version
4
- hash: 29
4
+ hash: 27
5
5
  prerelease: false
6
6
  segments:
7
7
  - 0
8
8
  - 0
9
- - 1
10
- version: 0.0.1
9
+ - 2
10
+ version: 0.0.2
11
11
  platform: ruby
12
12
  authors:
13
13
  - Chris Beer