puppet 7.7.0-x64-mingw32 → 7.8.0-x64-mingw32

Sign up to get free protection for your applications and to get access to all the features.

Potentially problematic release.


This version of puppet might be problematic. Click here for more details.

Files changed (54) hide show
  1. checksums.yaml +4 -4
  2. data/CONTRIBUTING.md +2 -2
  3. data/Gemfile +2 -1
  4. data/Gemfile.lock +9 -9
  5. data/ext/osx/puppet.plist +2 -0
  6. data/lib/puppet/defaults.rb +3 -1
  7. data/lib/puppet/pops/types/p_sem_ver_type.rb +8 -2
  8. data/lib/puppet/pops/types/p_sensitive_type.rb +10 -0
  9. data/lib/puppet/provider/package/apt.rb +3 -3
  10. data/lib/puppet/provider/package/nim.rb +11 -6
  11. data/lib/puppet/provider/package/yum.rb +3 -3
  12. data/lib/puppet/provider/package/zypper.rb +3 -3
  13. data/lib/puppet/provider/service/freebsd.rb +1 -1
  14. data/lib/puppet/provider/service/systemd.rb +6 -1
  15. data/lib/puppet/provider/user/directoryservice.rb +24 -11
  16. data/lib/puppet/transaction/additional_resource_generator.rb +1 -1
  17. data/lib/puppet/type/service.rb +8 -9
  18. data/lib/puppet/type/user.rb +38 -20
  19. data/lib/puppet/version.rb +1 -1
  20. data/locales/puppet.pot +36 -40
  21. data/man/man5/puppet.conf.5 +5 -2
  22. data/man/man8/puppet-agent.8 +1 -1
  23. data/man/man8/puppet-apply.8 +1 -1
  24. data/man/man8/puppet-catalog.8 +1 -1
  25. data/man/man8/puppet-config.8 +1 -1
  26. data/man/man8/puppet-describe.8 +1 -1
  27. data/man/man8/puppet-device.8 +1 -1
  28. data/man/man8/puppet-doc.8 +1 -1
  29. data/man/man8/puppet-epp.8 +1 -1
  30. data/man/man8/puppet-facts.8 +1 -1
  31. data/man/man8/puppet-filebucket.8 +1 -1
  32. data/man/man8/puppet-generate.8 +1 -1
  33. data/man/man8/puppet-help.8 +1 -1
  34. data/man/man8/puppet-lookup.8 +1 -1
  35. data/man/man8/puppet-module.8 +1 -1
  36. data/man/man8/puppet-node.8 +1 -1
  37. data/man/man8/puppet-parser.8 +1 -1
  38. data/man/man8/puppet-plugin.8 +1 -1
  39. data/man/man8/puppet-report.8 +1 -1
  40. data/man/man8/puppet-resource.8 +1 -1
  41. data/man/man8/puppet-script.8 +1 -1
  42. data/man/man8/puppet-ssl.8 +1 -1
  43. data/man/man8/puppet.8 +2 -2
  44. data/spec/integration/application/resource_spec.rb +30 -0
  45. data/spec/unit/functions4_spec.rb +17 -8
  46. data/spec/unit/pops/types/p_sem_ver_type_spec.rb +18 -0
  47. data/spec/unit/pops/types/p_sensitive_type_spec.rb +18 -0
  48. data/spec/unit/provider/package/nim_spec.rb +42 -0
  49. data/spec/unit/provider/service/freebsd_spec.rb +1 -1
  50. data/spec/unit/provider/service/systemd_spec.rb +12 -0
  51. data/spec/unit/provider/user/directoryservice_spec.rb +67 -35
  52. data/spec/unit/type/service_spec.rb +49 -34
  53. data/spec/unit/type/user_spec.rb +45 -0
  54. metadata +4 -2
@@ -174,6 +174,51 @@ describe Puppet::Type.type(:user) do
174
174
  end
175
175
  end
176
176
 
177
+ describe "when managing the purge_ssh_keys property" do
178
+ context "with valid input" do
179
+ it "should support a :true value" do
180
+ expect { described_class.new(:name => 'foo', :purge_ssh_keys => :true) }.to_not raise_error
181
+ end
182
+
183
+ it "should support a :false value" do
184
+ expect { described_class.new(:name => 'foo', :purge_ssh_keys => :false) }.to_not raise_error
185
+ end
186
+
187
+ it "should support a String value" do
188
+ expect { described_class.new(:name => 'foo', :purge_ssh_keys => File.expand_path('home/foo/.ssh/authorized_keys')) }.to_not raise_error
189
+ end
190
+
191
+ it "should support an Array value" do
192
+ expect { described_class.new(:name => 'foo', :purge_ssh_keys => [File.expand_path('home/foo/.ssh/authorized_keys'),
193
+ File.expand_path('custom/authorized_keys')]) }.to_not raise_error
194
+ end
195
+ end
196
+
197
+ context "with faulty input" do
198
+ it "should raise error for relative path" do
199
+ expect { described_class.new(:name => 'foo', :purge_ssh_keys => 'home/foo/.ssh/authorized_keys') }.to raise_error(Puppet::ResourceError,
200
+ /Paths to keyfiles must be absolute/ )
201
+ end
202
+
203
+ it "should raise error for invalid type" do
204
+ expect { described_class.new(:name => 'foo', :purge_ssh_keys => :invalid) }.to raise_error(Puppet::ResourceError,
205
+ /purge_ssh_keys must be true, false, or an array of file names/ )
206
+ end
207
+
208
+ it "should raise error for array with relative path" do
209
+ expect { described_class.new(:name => 'foo', :purge_ssh_keys => ['home/foo/.ssh/authorized_keys',
210
+ File.expand_path('custom/authorized_keys')]) }.to raise_error(Puppet::ResourceError,
211
+ /Paths to keyfiles must be absolute/ )
212
+ end
213
+
214
+ it "should raise error for array with invalid type" do
215
+ expect { described_class.new(:name => 'foo', :purge_ssh_keys => [:invalid,
216
+ File.expand_path('custom/authorized_keys')]) }.to raise_error(Puppet::ResourceError,
217
+ /Each entry for purge_ssh_keys must be a string/ )
218
+ end
219
+ end
220
+ end
221
+
177
222
  describe "when managing the uid property" do
178
223
  it "should convert number-looking strings into actual numbers" do
179
224
  expect(described_class.new(:name => 'foo', :uid => '50')[:uid]).to eq(50)
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: puppet
3
3
  version: !ruby/object:Gem::Version
4
- version: 7.7.0
4
+ version: 7.8.0
5
5
  platform: x64-mingw32
6
6
  authors:
7
7
  - Puppet Labs
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2021-05-25 00:00:00.000000000 Z
11
+ date: 2021-06-14 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: facter
@@ -1799,6 +1799,7 @@ files:
1799
1799
  - spec/integration/application/lookup_spec.rb
1800
1800
  - spec/integration/application/module_spec.rb
1801
1801
  - spec/integration/application/plugin_spec.rb
1802
+ - spec/integration/application/resource_spec.rb
1802
1803
  - spec/integration/configurer_spec.rb
1803
1804
  - spec/integration/data_binding_spec.rb
1804
1805
  - spec/integration/defaults_spec.rb
@@ -3037,6 +3038,7 @@ test_files:
3037
3038
  - spec/integration/application/lookup_spec.rb
3038
3039
  - spec/integration/application/module_spec.rb
3039
3040
  - spec/integration/application/plugin_spec.rb
3041
+ - spec/integration/application/resource_spec.rb
3040
3042
  - spec/integration/configurer_spec.rb
3041
3043
  - spec/integration/data_binding_spec.rb
3042
3044
  - spec/integration/defaults_spec.rb