chef-attribute-validator 0.3.1 → 0.3.2

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,15 +1,15 @@
1
1
  ---
2
2
  !binary "U0hBMQ==":
3
3
  metadata.gz: !binary |-
4
- ZDdiM2M5N2FjMTI2MjY4NWI0ZDViYzU5ZTAzZDAzNDBmZjgwMjkwNg==
4
+ MzE4YmM5ZjAyNGVjM2MyYTY5M2Q2OGFmMWE5YmM3YmRiNWFmNWNlZQ==
5
5
  data.tar.gz: !binary |-
6
- NjM3MmUzZDExMWJkMmNkNTYwMWFhNWMzNDA0ZDY1NDhmY2M0NzhiYg==
6
+ Y2FlNGQ5NTYyZWMzY2UzY2JjOTZmZmMwYzY3MzFiZGNiNjU2N2U2NA==
7
7
  SHA512:
8
8
  metadata.gz: !binary |-
9
- YjQwNjUzNTM5NjQ1NzBkZDZlYzEzMmQzOThjZmFmYzU5NTlhZGQ2MjMwYWMz
10
- ZmFlOGZlNzVjYWIwNGRmODM4MmMzMDc5YjE5ODgyOWYzZmJjYTNmNGEyODJi
11
- YTc5ZjRiMmU4YzE0YmY4YjBhMjdhOGU2NDYxNTI4NGE2MDJmOGI=
9
+ ZjM2NDdkOTBiMzQ3MDU5MmNkOGE1OGJlYzliZTY4ZWQ2NjZmNzcwODc0YmVl
10
+ OWEzZDdhYWYzOGExMmJiMDAwMTQ1OWYxNzg3MDYyZWE5ZmI4NjI4NDYzYWFj
11
+ ZTc3ODYzNTI0YTYxNTljNzdkOWNlN2RkNTIyZjI3MThiOWUzY2U=
12
12
  data.tar.gz: !binary |-
13
- NTg2YjY1ZWJiYzZlNjllNGVhNWYxYTlkYzc5NGViYjA1ZDFkYTE4MmRkMDk3
14
- NjA4Yjc1YjVkZjA2NTk2MTJjYmM1OWFkYjIxOGY5MDcyOTk1NmUyZjFmMGRj
15
- ODg5ZTVhZjEzMDFjMWNiNGRlYzU4MmI2ZmMzNzZjZTc3ZjRjNWU=
13
+ ZDdkYjUyOWM2OTIyYTcwNDZlYjA4OTQ2MDk0MDViOTIzMTExNDViZmRiOTVl
14
+ NzYyOGY0ZTIwOWZlOTI4OGQ0MzAzMjFkZWM5MmRmMmNjNTM3MmUyZjBmOWY0
15
+ MzhlZTNhODY3ODM1NzFmNjBlODNjN2VmODQ3ZTQ3ZDk3YmVkZTQ=
data/CHANGES CHANGED
@@ -1,3 +1,6 @@
1
+ 2013-11-15 Clinton Wolfe 0.3.2
2
+ umm wait regex should not violate if given a non-string - use type check if you want that
3
+
1
4
  2013-11-15 Clinton Wolfe 0.3.1
2
5
  regex check should violate, but not throw exception, when given a non-string
3
6
 
@@ -20,8 +20,6 @@ class Chef
20
20
  unless check_arg.match(value)
21
21
  violations.push Chef::Attribute::Validator::Violation.new(rule_name, path, "Attribute's value is '#{value}', which does not match regex '#{check_arg}'")
22
22
  end
23
- else
24
- violations.push Chef::Attribute::Validator::Violation.new(rule_name, path, "Attribute's value is '#{value}' (class #{value.class.name}), which is cannot be regexed")
25
23
  end
26
24
  end
27
25
  end
@@ -1,7 +1,7 @@
1
1
  class Chef
2
2
  class Attribute
3
3
  class Validator
4
- VERSION = "0.3.1"
4
+ VERSION = "0.3.2"
5
5
  end
6
6
  end
7
7
  end
@@ -58,14 +58,14 @@ describe "'regex' check" do
58
58
  expect(av.validate_rule('not-foo-foo')).not_to be_empty
59
59
  end
60
60
 
61
- it "/foo/ should violate on false" do
61
+ it "/foo/ should not violate on false" do
62
62
  expect { av.validate_rule('foo-false') }.not_to raise_error
63
- expect(av.validate_rule('foo-false')).not_to be_empty
63
+ expect(av.validate_rule('foo-false')).to be_empty
64
64
  end
65
65
 
66
- it "/foo/ should violate on 1" do
66
+ it "/foo/ should not violate on 1" do
67
67
  expect { av.validate_rule('foo-one') }.not_to raise_error
68
- expect(av.validate_rule('foo-one')).not_to be_empty
68
+ expect(av.validate_rule('foo-one')).to be_empty
69
69
  end
70
70
 
71
71
  end
metadata CHANGED
@@ -1,8 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: chef-attribute-validator
3
3
  version: !ruby/object:Gem::Version
4
- version: !binary |-
5
- MC4zLjE=
4
+ version: 0.3.2
6
5
  platform: ruby
7
6
  authors:
8
7
  - Clinton Wolfe