puppet-syntax 4.1.0 → 4.1.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.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 45c8f3b9275ea2f9c7cccb72c2b930a15079ff0618ee55d62d8b3d393ec3f8a1
4
- data.tar.gz: 11d6e05a07d6932b9180a9e09eb1e5c7cf47b209c7c935bd4d5635e51ce11bba
3
+ metadata.gz: a9f7f1ca6475068159902b6dbe227d6ac486336d2fc2ad1c8b00e38b71082597
4
+ data.tar.gz: 725e830cc518515bf10605391de65a324eb7caafc38c37f32f252cafe1f18ace
5
5
  SHA512:
6
- metadata.gz: 87e65a0f0e244ee179926e7e9b3904a5f0c77b87b6789a24f98efa18e78a8345312b434c5fbd051c92b9332572b19346a0bddad3623c341b6d9479ec6f55e094
7
- data.tar.gz: 2bfd3fae9730595def3f1892a753279a7a081ab9ba4f09f8dafc1c798e7aaf67c469886c1fca22a994274d02343a9d838d90a02c56f16dd0c4b65099c28a9404
6
+ metadata.gz: a677df82c7a0a758a8184bb8158a422105be48f9552d21bec36f9c1f5f0e67380559318f3dbc6dda464ea18d9e8ed4b515ac68416220bcaf826e2816790f98cf
7
+ data.tar.gz: 6f9849ab4f2f99ab59f0dbdcff21b31e8c76e0bdc8920c8cf0edabe2d4882e07d4f29e7cdd6b8a4a32e8539b19a7a1b6b4cfa8002e666835ba92ac0358110eb2
data/.rubocop_todo.yml CHANGED
@@ -86,7 +86,7 @@ RSpec/DescribedClass:
86
86
  # Offense count: 7
87
87
  # Configuration parameters: CountAsOne.
88
88
  RSpec/ExampleLength:
89
- Max: 16
89
+ Max: 17
90
90
 
91
91
  # Offense count: 4
92
92
  # Configuration parameters: Include, CustomTransform, IgnoreMethods, SpecSuffixOnly.
@@ -100,7 +100,7 @@ RSpec/FilePath:
100
100
 
101
101
  # Offense count: 29
102
102
  RSpec/MultipleExpectations:
103
- Max: 10
103
+ Max: 11
104
104
 
105
105
  # Offense count: 30
106
106
  # Configuration parameters: EnforcedStyle, IgnoreSharedExamples.
data/CHANGELOG.md CHANGED
@@ -2,6 +2,14 @@
2
2
 
3
3
  All notable changes to this project will be documented in this file.
4
4
 
5
+ ## [v4.1.1](https://github.com/voxpupuli/puppet-syntax/tree/v4.1.1) (2024-04-04)
6
+
7
+ [Full Changelog](https://github.com/voxpupuli/puppet-syntax/compare/v4.1.0...v4.1.1)
8
+
9
+ **Fixed bugs:**
10
+
11
+ - fix too greedy regular expression [\#171](https://github.com/voxpupuli/puppet-syntax/pull/171) ([tmu-sprd](https://github.com/tmu-sprd))
12
+
5
13
  ## [v4.1.0](https://github.com/voxpupuli/puppet-syntax/tree/v4.1.0) (2024-03-12)
6
14
 
7
15
  [Full Changelog](https://github.com/voxpupuli/puppet-syntax/compare/v4.0.1...v4.1.0)
@@ -122,7 +122,7 @@ module PuppetSyntax
122
122
  # You can do string concatenation outside of {}:
123
123
  # "%{lookup('this_is_ok')}:3306"
124
124
  def check_broken_function_call(element)
125
- 'string after a function call but before `}` in the value' if element.is_a?(String) && /%{.+\('.*'\).+}/.match?(element)
125
+ 'string after a function call but before `}` in the value' if element.is_a?(String) && /%{[^}]+\('[^}]*'\)[^}\s]+}/.match?(element)
126
126
  end
127
127
 
128
128
  # gets a hash or array, returns all keys + values as array
@@ -1,3 +1,3 @@
1
1
  module PuppetSyntax
2
- VERSION = '4.1.0'
2
+ VERSION = '4.1.1'
3
3
  end
@@ -24,5 +24,5 @@ Gem::Specification.new do |spec|
24
24
  spec.add_development_dependency 'pry', '~> 0.14.2'
25
25
  spec.add_development_dependency 'rb-readline', '~> 0.5.5'
26
26
 
27
- spec.add_development_dependency 'voxpupuli-rubocop', '~> 2.5.0'
27
+ spec.add_development_dependency 'voxpupuli-rubocop', '~> 2.6.0'
28
28
  end
@@ -3,6 +3,7 @@ this_is_ok: 0
3
3
  this_is_ok::too: 0
4
4
  th1s_is_ok::two3: 0
5
5
  :eventhis: 0
6
+ this_is_ok::concat_func: "%{lookup('foo')}%{lookup('bar')}"
6
7
 
7
8
  typical:typo::warning1: true
8
9
  ::notsotypical::warning2: true
@@ -15,3 +16,4 @@ this_is::warning7:
15
16
  - "%{lookup('foobar'):3306}"
16
17
  this_is::warning8:
17
18
  foo: "%{lookup('foobar'):3306}"
19
+ this_is::warning9: "%{lookup('foo'):3306}%{lookup('bar')}"
@@ -29,7 +29,7 @@ describe PuppetSyntax::Hiera do
29
29
 
30
30
  it 'returns warnings for invalid keys' do
31
31
  hiera_yaml = 'hiera_badkey.yaml'
32
- examples = 8
32
+ examples = 9
33
33
  files = fixture_hiera(hiera_yaml)
34
34
  res = subject.check(files)
35
35
  (1..examples).each do |n|
@@ -44,6 +44,7 @@ describe PuppetSyntax::Hiera do
44
44
  expect(res[5]).to match('Key :this_is::warning6: string after a function call but before `}` in the value')
45
45
  expect(res[6]).to match('Key :this_is::warning7: string after a function call but before `}` in the value')
46
46
  expect(res[7]).to match('Key :this_is::warning8: string after a function call but before `}` in the value')
47
+ expect(res[8]).to match('Key :this_is::warning9: string after a function call but before `}` in the value')
47
48
  end
48
49
 
49
50
  it 'returns warnings for bad eyaml values' do
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: puppet-syntax
3
3
  version: !ruby/object:Gem::Version
4
- version: 4.1.0
4
+ version: 4.1.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - Vox Pupuli
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2024-03-12 00:00:00.000000000 Z
11
+ date: 2024-04-04 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: puppet
@@ -78,14 +78,14 @@ dependencies:
78
78
  requirements:
79
79
  - - "~>"
80
80
  - !ruby/object:Gem::Version
81
- version: 2.5.0
81
+ version: 2.6.0
82
82
  type: :development
83
83
  prerelease: false
84
84
  version_requirements: !ruby/object:Gem::Requirement
85
85
  requirements:
86
86
  - - "~>"
87
87
  - !ruby/object:Gem::Version
88
- version: 2.5.0
88
+ version: 2.6.0
89
89
  description: Syntax checks for Puppet manifests and templates
90
90
  email:
91
91
  - voxpupuli@groups.io