simp-rspec-puppet-facts 3.0.0 → 3.1.0

Sign up to get free protection for your applications and to get access to all the features.
@@ -0,0 +1,429 @@
1
+ {
2
+ "aio_agent_version": "5.5.18",
3
+ "architecture": "x64",
4
+ "archive_windir": "C:\\ProgramData\\staging",
5
+ "dhcp_servers": {
6
+ "Ethernet": "10.0.2.2",
7
+ "system": "10.0.2.2"
8
+ },
9
+ "dmi": {
10
+ "manufacturer": "innotek GmbH",
11
+ "product": {
12
+ "name": "VirtualBox",
13
+ "serial_number": "0",
14
+ "uuid": "204E055A-EADF-F640-A9F9-9F9816B499F5"
15
+ }
16
+ },
17
+ "domain": "example.com",
18
+ "env_windows_installdir": "C:\\Program Files\\Puppet Labs\\Puppet",
19
+ "facterversion": "3.11.11",
20
+ "fips_enabled": false,
21
+ "fqdn": "foo.example.com",
22
+ "hardwareisa": "x64",
23
+ "hardwaremodel": "x86_64",
24
+ "hostname": "foo",
25
+ "hypervisors": {
26
+ "virtualbox": {
27
+ "revision": "135406",
28
+ "version": "6.1.0"
29
+ }
30
+ },
31
+ "id": "WIN\\vagrant",
32
+ "identity": {
33
+ "privileged": true,
34
+ "user": "WIN\\vagrant"
35
+ },
36
+ "interfaces": "Ethernet",
37
+ "ipaddress": "10.0.2.15",
38
+ "ipaddress6": "fe80::61a1:d122:9a4c:eb09",
39
+ "ipaddress6_Ethernet": "fe80::61a1:d122:9a4c:eb09",
40
+ "ipaddress_Ethernet": "10.0.2.15",
41
+ "is_pe": false,
42
+ "is_virtual": true,
43
+ "kernel": "windows",
44
+ "kernelmajversion": "10.0",
45
+ "kernelrelease": "10.0.17763",
46
+ "kernelversion": "10.0.17763",
47
+ "macaddress": "08:00:27:E2:4C:85",
48
+ "macaddress_Ethernet": "08:00:27:E2:4C:85",
49
+ "manufacturer": "innotek GmbH",
50
+ "memory": {
51
+ "system": {
52
+ "available": "1.23 GiB",
53
+ "available_bytes": 1323552768,
54
+ "capacity": "38.35%",
55
+ "total": "2.00 GiB",
56
+ "total_bytes": 2147012608,
57
+ "used": "785.31 MiB",
58
+ "used_bytes": 823459840
59
+ }
60
+ },
61
+ "memoryfree": "1.23 GiB",
62
+ "memoryfree_mb": 1262.23828125,
63
+ "memorysize": "2.00 GiB",
64
+ "memorysize_mb": 2047.55078125,
65
+ "mtu_Ethernet": 1500,
66
+ "netmask": "255.255.0.0",
67
+ "netmask6": "ffff:ffff:ffff:ffff::",
68
+ "netmask6_Ethernet": "ffff:ffff:ffff:ffff::",
69
+ "netmask_Ethernet": "255.255.0.0",
70
+ "network": "10.0.2.0",
71
+ "network6": "fe80::",
72
+ "network6_Ethernet": "fe80::",
73
+ "network_Ethernet": "10.0.2.0",
74
+ "networking": {
75
+ "dhcp": "10.0.2.2",
76
+ "domain": "example.com",
77
+ "fqdn": "foo.example.com",
78
+ "hostname": "foo",
79
+ "interfaces": {
80
+ "Ethernet": {
81
+ "bindings": [
82
+ {
83
+ "address": "10.0.2.15",
84
+ "netmask": "255.255.0.0",
85
+ "network": "10.0.2.0"
86
+ }
87
+ ],
88
+ "bindings6": [
89
+ {
90
+ "address": "fe80::61a1:d122:9a4c:eb09",
91
+ "netmask": "ffff:ffff:ffff:ffff::",
92
+ "network": "fe80::"
93
+ }
94
+ ],
95
+ "dhcp": "10.0.2.2",
96
+ "ip": "10.0.2.15",
97
+ "ip6": "fe80::61a1:d122:9a4c:eb09",
98
+ "mac": "08:00:27:E2:4C:85",
99
+ "mtu": 1500,
100
+ "netmask": "255.255.0.0",
101
+ "netmask6": "ffff:ffff:ffff:ffff::",
102
+ "network": "10.0.2.0",
103
+ "network6": "fe80::",
104
+ "scope6": "link"
105
+ }
106
+ },
107
+ "ip": "10.0.2.15",
108
+ "ip6": "fe80::61a1:d122:9a4c:eb09",
109
+ "mac": "08:00:27:E2:4C:85",
110
+ "mtu": 1500,
111
+ "netmask": "255.255.0.0",
112
+ "netmask6": "ffff:ffff:ffff:ffff::",
113
+ "network": "10.0.2.0",
114
+ "network6": "fe80::",
115
+ "primary": "Ethernet",
116
+ "scope6": "link"
117
+ },
118
+ "openldap_arch": "i386",
119
+ "operatingsystem": "windows",
120
+ "operatingsystemmajrelease": "2019",
121
+ "operatingsystemrelease": "2019",
122
+ "os": {
123
+ "architecture": "x64",
124
+ "family": "windows",
125
+ "hardware": "x86_64",
126
+ "name": "windows",
127
+ "release": {
128
+ "full": "2019",
129
+ "major": "2019"
130
+ },
131
+ "windows": {
132
+ "edition_id": "ServerStandardEval",
133
+ "installation_type": "Server",
134
+ "product_name": "Windows Server 2019 Standard Evaluation",
135
+ "release_id": "1809",
136
+ "system32": "C:\\Windows\\system32"
137
+ }
138
+ },
139
+ "osfamily": "windows",
140
+ "package_provider": "windows",
141
+ "path": "C:\\Program Files\\Puppet Labs\\Puppet\\facter/bin;C:\\Program Files\\Puppet Labs\\Puppet\\facter/../puppet/bin;C:\\Program Files\\Puppet Labs\\Puppet\\puppet\\bin;C:\\Program Files\\Puppet Labs\\Puppet\\facter\\bin;C:\\Program Files\\Puppet Labs\\Puppet\\hiera\\bin;C:\\Program Files\\Puppet Labs\\Puppet\\mcollective\\bin;C:\\Program Files\\Puppet Labs\\Puppet\\bin;C:\\Program Files\\Puppet Labs\\Puppet\\sys\\ruby\\bin;C:\\Program Files\\Puppet Labs\\Puppet\\sys\\tools\\bin;C:\\Windows\\system32;C:\\Windows;C:\\Windows\\System32\\Wbem;C:\\Windows\\System32\\WindowsPowerShell\\v1.0\\;C:\\Windows\\System32\\OpenSSH\\;C:\\ProgramData\\chocolatey\\bin;C:\\Program Files\\OpenSSH-Win64;C:\\opscode\\chef\\bin\\;C:\\Program Files\\Puppet Labs\\Puppet\\bin;C:\\Windows\\system32\\config\\systemprofile\\AppData\\Local\\Microsoft\\WindowsApps;C:\\Users\\vagrant\\AppData\\Local\\Microsoft\\WindowsApps;",
142
+ "physicalprocessorcount": 1,
143
+ "processor0": "Intel(R) Core(TM) i7-4930K CPU @ 3.40GHz",
144
+ "processorcount": 2,
145
+ "processors": {
146
+ "count": 2,
147
+ "isa": "x64",
148
+ "models": [
149
+ "Intel(R) Core(TM) i7-4930K CPU @ 3.40GHz"
150
+ ],
151
+ "physicalcount": 1
152
+ },
153
+ "productname": "VirtualBox",
154
+ "puppet_environmentpath": "C:/ProgramData/PuppetLabs/code/environments",
155
+ "puppet_ruby_dir": "C:/Program Files/Puppet Labs/Puppet/sys/ruby/lib/ruby/vendor_ruby/puppet",
156
+ "puppet_server": "puppet",
157
+ "puppet_settings": {
158
+ "main": {
159
+ "confdir": "C:/ProgramData/PuppetLabs/puppet/etc",
160
+ "codedir": "C:/ProgramData/PuppetLabs/code",
161
+ "vardir": "C:/ProgramData/PuppetLabs/puppet/cache",
162
+ "name": "facts",
163
+ "logdir": "C:/ProgramData/PuppetLabs/puppet/var/log",
164
+ "log_level": "notice",
165
+ "disable_warnings": "[]",
166
+ "strict": "warning",
167
+ "disable_i18n": "false",
168
+ "priority": "",
169
+ "trace": "false",
170
+ "puppet_trace": "false",
171
+ "profile": "false",
172
+ "future_features": "false",
173
+ "static_catalogs": "true",
174
+ "strict_environment_mode": "false",
175
+ "autoflush": "true",
176
+ "syslogfacility": "daemon",
177
+ "statedir": "C:/ProgramData/PuppetLabs/puppet/cache/state",
178
+ "rundir": "C:/ProgramData/PuppetLabs/puppet/var/run",
179
+ "genconfig": "false",
180
+ "genmanifest": "false",
181
+ "color": "ansi",
182
+ "mkusers": "false",
183
+ "manage_internal_file_permissions": "false",
184
+ "onetime": "false",
185
+ "path": "none",
186
+ "libdir": "C:/ProgramData/PuppetLabs/puppet/cache/lib",
187
+ "environment": "production",
188
+ "environmentpath": "C:/ProgramData/PuppetLabs/code/environments",
189
+ "always_retry_plugins": "true",
190
+ "diff_args": "-u",
191
+ "diff": "",
192
+ "show_diff": "false",
193
+ "daemonize": "false",
194
+ "maximum_uid": "4294967290",
195
+ "route_file": "C:/ProgramData/PuppetLabs/puppet/etc/routes.yaml",
196
+ "node_terminus": "plain",
197
+ "node_cache_terminus": "",
198
+ "data_binding_terminus": "hiera",
199
+ "hiera_config": "C:/ProgramData/PuppetLabs/puppet/etc/hiera.yaml",
200
+ "binder_config": "",
201
+ "catalog_terminus": "compiler",
202
+ "catalog_cache_terminus": "",
203
+ "facts_terminus": "facter",
204
+ "default_file_terminus": "rest",
205
+ "http_proxy_host": "none",
206
+ "http_proxy_port": "3128",
207
+ "http_proxy_user": "none",
208
+ "http_proxy_password": "none",
209
+ "no_proxy": "localhost, 127.0.0.1",
210
+ "http_keepalive_timeout": "4",
211
+ "http_debug": "false",
212
+ "http_connect_timeout": "120",
213
+ "http_read_timeout": "",
214
+ "http_user_agent": "Puppet/5.5.18 Ruby/2.4.9-p362 (x64-mingw32)",
215
+ "filetimeout": "15",
216
+ "environment_timeout": "0",
217
+ "environment_data_provider": "",
218
+ "prerun_command": "",
219
+ "postrun_command": "",
220
+ "freeze_main": "false",
221
+ "preview_outputdir": "C:/ProgramData/PuppetLabs/puppet/cache/preview",
222
+ "certname": "foo.example.com",
223
+ "dns_alt_names": "",
224
+ "csr_attributes": "C:/ProgramData/PuppetLabs/puppet/etc/csr_attributes.yaml",
225
+ "certdir": "C:/ProgramData/PuppetLabs/puppet/etc/ssl/certs",
226
+ "ssldir": "C:/ProgramData/PuppetLabs/puppet/etc/ssl",
227
+ "publickeydir": "C:/ProgramData/PuppetLabs/puppet/etc/ssl/public_keys",
228
+ "requestdir": "C:/ProgramData/PuppetLabs/puppet/etc/ssl/certificate_requests",
229
+ "privatekeydir": "C:/ProgramData/PuppetLabs/puppet/etc/ssl/private_keys",
230
+ "privatedir": "C:/ProgramData/PuppetLabs/puppet/etc/ssl/private",
231
+ "passfile": "C:/ProgramData/PuppetLabs/puppet/etc/ssl/private/password",
232
+ "hostcsr": "C:/ProgramData/PuppetLabs/puppet/etc/ssl/csr_foo.example.com.pem",
233
+ "hostcert": "C:/ProgramData/PuppetLabs/puppet/etc/ssl/certs/foo.example.com.pem",
234
+ "hostprivkey": "C:/ProgramData/PuppetLabs/puppet/etc/ssl/private_keys/foo.example.com.pem",
235
+ "hostpubkey": "C:/ProgramData/PuppetLabs/puppet/etc/ssl/public_keys/foo.example.com.pem",
236
+ "localcacert": "C:/ProgramData/PuppetLabs/puppet/etc/ssl/certs/ca.pem",
237
+ "ssl_client_ca_auth": "",
238
+ "ssl_server_ca_auth": "",
239
+ "hostcrl": "C:/ProgramData/PuppetLabs/puppet/etc/ssl/crl.pem",
240
+ "certificate_revocation": "chain",
241
+ "digest_algorithm": "md5",
242
+ "supported_checksum_types": "[\"md5\", \"sha256\", \"sha384\", \"sha512\", \"sha224\"]",
243
+ "logdest": "",
244
+ "plugindest": "C:/ProgramData/PuppetLabs/puppet/cache/lib",
245
+ "pluginsource": "puppet:///plugins",
246
+ "pluginfactdest": "C:/ProgramData/PuppetLabs/puppet/cache/facts.d",
247
+ "pluginfactsource": "puppet:///pluginfacts",
248
+ "localedest": "C:/ProgramData/PuppetLabs/puppet/cache/locales",
249
+ "localesource": "puppet:///locales",
250
+ "pluginsync": "true",
251
+ "pluginsignore": ".svn CVS .git .hg",
252
+ "factpath": "C:/ProgramData/PuppetLabs/puppet/cache/lib/facter;C:/ProgramData/PuppetLabs/puppet/cache/facts",
253
+ "external_nodes": "none",
254
+ "rich_data": "false"
255
+ },
256
+ "module_tool": {
257
+ "module_repository": "https://forgeapi.puppet.com",
258
+ "module_working_dir": "C:/Users/vagrant/AppData/Local/Temp",
259
+ "module_skeleton_dir": "C:/Users/vagrant/AppData/Local/Temp/skeleton",
260
+ "forge_authorization": "",
261
+ "module_groups": ""
262
+ },
263
+ "ca": {
264
+ "ca_name": "Puppet CA: foo.example.com",
265
+ "cadir": "C:/ProgramData/PuppetLabs/puppet/etc/ssl/ca",
266
+ "cacert": "C:/ProgramData/PuppetLabs/puppet/etc/ssl/ca/ca_crt.pem",
267
+ "cakey": "C:/ProgramData/PuppetLabs/puppet/etc/ssl/ca/ca_key.pem",
268
+ "capub": "C:/ProgramData/PuppetLabs/puppet/etc/ssl/ca/ca_pub.pem",
269
+ "cacrl": "C:/ProgramData/PuppetLabs/puppet/etc/ssl/ca/ca_crl.pem",
270
+ "caprivatedir": "C:/ProgramData/PuppetLabs/puppet/etc/ssl/ca/private",
271
+ "csrdir": "C:/ProgramData/PuppetLabs/puppet/etc/ssl/ca/requests",
272
+ "signeddir": "C:/ProgramData/PuppetLabs/puppet/etc/ssl/ca/signed",
273
+ "capass": "C:/ProgramData/PuppetLabs/puppet/etc/ssl/ca/private/ca.pass",
274
+ "serial": "C:/ProgramData/PuppetLabs/puppet/etc/ssl/ca/serial",
275
+ "autosign": "C:/ProgramData/PuppetLabs/puppet/etc/autosign.conf",
276
+ "allow_duplicate_certs": "false",
277
+ "ca_ttl": "157680000",
278
+ "keylength": "4096",
279
+ "cert_inventory": "C:/ProgramData/PuppetLabs/puppet/etc/ssl/ca/inventory.txt"
280
+ },
281
+ "application": {
282
+ "config_file_name": "puppet.conf",
283
+ "config": "C:/ProgramData/PuppetLabs/puppet/etc/puppet.conf",
284
+ "pidfile": "C:/ProgramData/PuppetLabs/puppet/var/run/application.pid",
285
+ "sourceaddress": ""
286
+ },
287
+ "environment": {
288
+ "manifest": "C:/ProgramData/PuppetLabs/code/environments/production/manifests",
289
+ "modulepath": "C:/ProgramData/PuppetLabs/code/environments/production/modules;C:/ProgramData/PuppetLabs/code/modules",
290
+ "config_version": ""
291
+ },
292
+ "master": {
293
+ "user": "puppet",
294
+ "group": "puppet",
295
+ "default_manifest": "./manifests",
296
+ "disable_per_environment_manifest": "false",
297
+ "code": "",
298
+ "masterport": "8140",
299
+ "node_name": "cert",
300
+ "bucketdir": "C:/ProgramData/PuppetLabs/puppet/cache/bucket",
301
+ "ca": "true",
302
+ "trusted_oid_mapping_file": "C:/ProgramData/PuppetLabs/puppet/etc/custom_trusted_oid_mapping.yaml",
303
+ "basemodulepath": "C:/ProgramData/PuppetLabs/code/modules",
304
+ "ssl_client_header": "HTTP_X_CLIENT_DN",
305
+ "ssl_client_verify_header": "HTTP_X_CLIENT_VERIFY",
306
+ "yamldir": "C:/ProgramData/PuppetLabs/puppet/cache/yaml",
307
+ "server_datadir": "C:/ProgramData/PuppetLabs/puppet/cache/server_data",
308
+ "reports": "store",
309
+ "reportdir": "C:/ProgramData/PuppetLabs/puppet/cache/reports",
310
+ "reporturl": "http://localhost:3000/reports/upload",
311
+ "fileserverconfig": "C:/ProgramData/PuppetLabs/puppet/etc/fileserver.conf",
312
+ "strict_hostname_checking": "false",
313
+ "storeconfigs": "false",
314
+ "storeconfigs_backend": "puppetdb"
315
+ },
316
+ "device": {
317
+ "devicedir": "C:/ProgramData/PuppetLabs/puppet/cache/devices",
318
+ "deviceconfig": "C:/ProgramData/PuppetLabs/puppet/etc/device.conf"
319
+ },
320
+ "agent": {
321
+ "node_name_value": "foo.example.com",
322
+ "node_name_fact": "",
323
+ "statefile": "C:/ProgramData/PuppetLabs/puppet/cache/state/state.yaml",
324
+ "statettl": "2764800",
325
+ "transactionstorefile": "C:/ProgramData/PuppetLabs/puppet/cache/state/transactionstore.yaml",
326
+ "clientyamldir": "C:/ProgramData/PuppetLabs/puppet/cache/client_yaml",
327
+ "client_datadir": "C:/ProgramData/PuppetLabs/puppet/cache/client_data",
328
+ "classfile": "C:/ProgramData/PuppetLabs/puppet/cache/state/classes.txt",
329
+ "resourcefile": "C:/ProgramData/PuppetLabs/puppet/cache/state/resources.txt",
330
+ "puppetdlog": "C:/ProgramData/PuppetLabs/puppet/var/log/puppetd.log",
331
+ "server": "puppet",
332
+ "server_list": "[]",
333
+ "use_srv_records": "false",
334
+ "srv_domain": "example.com",
335
+ "ignoreschedules": "false",
336
+ "default_schedules": "true",
337
+ "noop": "false",
338
+ "runinterval": "1800",
339
+ "runtimeout": "0",
340
+ "ca_server": "puppet",
341
+ "ca_port": "8140",
342
+ "preferred_serialization_format": "json",
343
+ "agent_catalog_run_lockfile": "C:/ProgramData/PuppetLabs/puppet/cache/state/agent_catalog_run.lock",
344
+ "agent_disabled_lockfile": "C:/ProgramData/PuppetLabs/puppet/cache/state/agent_disabled.lock",
345
+ "usecacheonfailure": "true",
346
+ "use_cached_catalog": "false",
347
+ "ignoremissingtypes": "false",
348
+ "splaylimit": "1800",
349
+ "splay": "false",
350
+ "clientbucketdir": "C:/ProgramData/PuppetLabs/puppet/cache/clientbucket",
351
+ "report_server": "puppet",
352
+ "report_port": "8140",
353
+ "report": "true",
354
+ "resubmit_facts": "false",
355
+ "lastrunfile": "C:/ProgramData/PuppetLabs/puppet/cache/state/last_run_summary.yaml",
356
+ "lastrunreport": "C:/ProgramData/PuppetLabs/puppet/cache/state/last_run_report.yaml",
357
+ "graph": "false",
358
+ "graphdir": "C:/ProgramData/PuppetLabs/puppet/cache/state/graphs",
359
+ "waitforcert": "120",
360
+ "ordering": "manifest"
361
+ },
362
+ "transaction": {
363
+ "tags": "",
364
+ "skip_tags": "",
365
+ "evaltrace": "false",
366
+ "summarize": "false"
367
+ },
368
+ "ldap": {
369
+ "ldapssl": "false",
370
+ "ldaptls": "false",
371
+ "ldapserver": "ldap",
372
+ "ldapport": "389",
373
+ "ldapstring": "(&(objectclass=puppetClient)(cn=%s))",
374
+ "ldapclassattrs": "puppetclass",
375
+ "ldapstackedattrs": "puppetvar",
376
+ "ldapattrs": "all",
377
+ "ldapparentattr": "parentnode",
378
+ "ldapuser": "",
379
+ "ldappassword": "",
380
+ "ldapbase": ""
381
+ },
382
+ "parser": {
383
+ "max_errors": "10",
384
+ "max_warnings": "10",
385
+ "max_deprecations": "10",
386
+ "strict_variables": "false",
387
+ "tasks": "false"
388
+ },
389
+ "puppetdoc": {
390
+ "document_all": "false"
391
+ }
392
+ },
393
+ "puppet_vardir": "C:/ProgramData/PuppetLabs/puppet/cache",
394
+ "puppetversion": "5.5.18",
395
+ "reboot_required": false,
396
+ "ruby": {
397
+ "platform": "x64-mingw32",
398
+ "sitedir": "C:/Program Files/Puppet Labs/Puppet/sys/ruby/lib/ruby/site_ruby/2.4.0",
399
+ "version": "2.4.9"
400
+ },
401
+ "rubyplatform": "x64-mingw32",
402
+ "rubysitedir": "C:/Program Files/Puppet Labs/Puppet/sys/ruby/lib/ruby/site_ruby/2.4.0",
403
+ "rubyversion": "2.4.9",
404
+ "scope6": "link",
405
+ "scope6_Ethernet": "link",
406
+ "serialnumber": "0",
407
+ "service_provider": "windows",
408
+ "system32": "C:\\Windows\\system32",
409
+ "system_uptime": {
410
+ "days": 0,
411
+ "hours": 0,
412
+ "seconds": 244,
413
+ "uptime": "0:04 hours"
414
+ },
415
+ "timezone": "Coordinated Universal Time",
416
+ "uptime": "0:04 hours",
417
+ "uptime_days": 0,
418
+ "uptime_hours": 0,
419
+ "uptime_seconds": 244,
420
+ "uuid": "204E055A-EADF-F640-A9F9-9F9816B499F5",
421
+ "virtual": "virtualbox",
422
+ "windows_edition_id": "ServerStandardEval",
423
+ "windows_installation_type": "Server",
424
+ "windows_product_name": "Windows Server 2019 Standard Evaluation",
425
+ "windows_release_id": "1809",
426
+ "clientcert": "foo.example.com",
427
+ "clientversion": "5.5.18",
428
+ "clientnoop": false
429
+ }
@@ -42,15 +42,14 @@ module Simp::RspecPuppetFacts
42
42
  end
43
43
 
44
44
  def on_supported_os( opts = {} )
45
- opts[:selinux_mode] ||= :enforcing
46
- opts[:simp_fact_dir_path] ||= File.expand_path("../../facts/",
47
- File.dirname(__FILE__))
45
+ opts[:simp_fact_dir_path] ||= File.expand_path("../../facts/", File.dirname(__FILE__))
48
46
 
49
- simp_h = load_facts(opts[:simp_fact_dir_path])
50
- strings = supported_os_strings(opts)
51
- masked_opts = filter_opts(opts, simp_h, :reject)
52
- selected_opts = filter_opts(opts, simp_h, :select)
53
- rfh_h = Simp::RspecPuppetFacts::Shim.on_supported_os(masked_opts)
47
+ simp_h = load_facts(opts[:simp_fact_dir_path])
48
+
49
+ masked_opts = filter_opts(opts, simp_h, :reject)
50
+
51
+ rfh_h = {}
52
+ rfh_h = Simp::RspecPuppetFacts::Shim.on_supported_os(masked_opts) unless masked_opts[:supported_os]&.empty?
54
53
 
55
54
  h = rfh_h.merge(simp_h).select{|k,v| supported_os_strings(opts).include? k}
56
55
 
@@ -86,9 +85,8 @@ module Simp::RspecPuppetFacts
86
85
  h
87
86
  end
88
87
 
89
-
90
88
  def lsb_facts( facts )
91
- return facts if facts[:kernel].casecmp('windows')
89
+ return facts unless facts[:kernel].casecmp('linux')
92
90
 
93
91
  lsb_facts = {}
94
92
  # attempt to massage a major release version if missing (for facter 1.6)
@@ -101,7 +99,9 @@ module Simp::RspecPuppetFacts
101
99
  lsb_facts
102
100
  end
103
101
 
104
- def selinux_facts( mode, facts )
102
+ def selinux_facts( mode=:enforcing, facts )
103
+ return facts if facts[:kernel]&.casecmp('windows')
104
+
105
105
  unless SELINUX_MODES.include?( mode )
106
106
  fail "FATAL: `mode` must be one of: #{SELINUX_MODES.map{|x| x.to_s.sub(/^/,':')}.join(', ')}"
107
107
  end