puppet-syntax 1.4.0 → 1.4.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/CHANGELOG CHANGED
@@ -1,3 +1,6 @@
1
+ 2015-01-08 Release 1.4.1
2
+ - Support appending to config arrays, thanks @domcleal
3
+
1
4
  2014-12-04 Release 1.4.0
2
5
  - Rspec 3 is now supported, thanks @tuxmea
3
6
  - Build error fixed where gem_publisher was used prematurely
data/lib/puppet-syntax.rb CHANGED
@@ -4,19 +4,11 @@ require "puppet-syntax/templates"
4
4
  require "puppet-syntax/hiera"
5
5
 
6
6
  module PuppetSyntax
7
+ @exclude_paths = []
8
+ @future_parser = false
9
+ @hieradata_paths = ["**/data/**/*.yaml", "hieradata/**/*.yaml", "hiera*.yaml"]
10
+
7
11
  class << self
8
12
  attr_accessor :exclude_paths, :future_parser, :hieradata_paths
9
-
10
- def exclude_paths
11
- @exclude_paths || []
12
- end
13
-
14
- def future_parser
15
- @future_parser || false
16
- end
17
-
18
- def hieradata_paths
19
- @hieradata_paths || ["**/data/**/*.yaml", "hieradata/**/*.yaml", "hiera*.yaml"]
20
- end
21
13
  end
22
14
  end
@@ -1,3 +1,3 @@
1
1
  module PuppetSyntax
2
- VERSION = "1.4.0"
2
+ VERSION = "1.4.1"
3
3
  end
@@ -1,6 +1,10 @@
1
1
  require 'spec_helper'
2
2
 
3
3
  describe PuppetSyntax do
4
+ after do
5
+ PuppetSyntax.exclude_paths = []
6
+ end
7
+
4
8
  it 'should default exclude_paths to empty array' do
5
9
  expect(PuppetSyntax.exclude_paths).to be_empty
6
10
  end
@@ -10,6 +14,11 @@ describe PuppetSyntax do
10
14
  expect(PuppetSyntax.exclude_paths).to eq(["foo", "bar/baz"])
11
15
  end
12
16
 
17
+ it 'should support appending exclude_paths' do
18
+ PuppetSyntax.exclude_paths << "foo"
19
+ expect(PuppetSyntax.exclude_paths).to eq(["foo"])
20
+ end
21
+
13
22
  it 'should support future parser setting' do
14
23
  PuppetSyntax.future_parser = true
15
24
  expect(PuppetSyntax.future_parser).to eq(true)
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: puppet-syntax
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.4.0
4
+ version: 1.4.1
5
5
  prerelease:
6
6
  platform: ruby
7
7
  authors:
@@ -9,7 +9,7 @@ authors:
9
9
  autorequire:
10
10
  bindir: bin
11
11
  cert_chain: []
12
- date: 2014-12-18 00:00:00.000000000 Z
12
+ date: 2015-01-08 00:00:00.000000000 Z
13
13
  dependencies:
14
14
  - !ruby/object:Gem::Dependency
15
15
  name: rake
@@ -115,7 +115,7 @@ required_ruby_version: !ruby/object:Gem::Requirement
115
115
  version: '0'
116
116
  segments:
117
117
  - 0
118
- hash: 2107948252144902184
118
+ hash: -3142815382772503907
119
119
  required_rubygems_version: !ruby/object:Gem::Requirement
120
120
  none: false
121
121
  requirements:
@@ -124,7 +124,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
124
124
  version: '0'
125
125
  segments:
126
126
  - 0
127
- hash: 2107948252144902184
127
+ hash: -3142815382772503907
128
128
  requirements: []
129
129
  rubyforge_project:
130
130
  rubygems_version: 1.8.23.2