fauxhai 6.9.0 → 6.9.1

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: db8b54eff84bac4e53003ac83c760fd8b59d44ee25c6f39e855dc041e9fa00bf
4
- data.tar.gz: d5cc8a150a845e3fe44ca0c898e98e0d23e98d0d1b88b4eb199f14c22c9a9ec5
3
+ metadata.gz: d4fd30cdc8c82218fa8500db789678d42096825a5f2ae91c40819df1a7aacec9
4
+ data.tar.gz: 810a063934cf1e3eca3867a7c98fa387293a6f706dff2e375821da9b02ad485f
5
5
  SHA512:
6
- metadata.gz: 36ca4fc48ce3e08e9d95aee28ecd4cb778dd33a075de372149372c702ccb42b31c6f49ea4a633453d7b355fdacd1af58f459c7b9257e079d9298324517a4493a
7
- data.tar.gz: b66ec0e63a936dd0828da13acd5658e4ef7cf55ec2dc0575f1bc2e92f7eea93ec9017dec783329b92e7bf37d2b366317f822f4de63cc64c3373ab7583c842bfd
6
+ metadata.gz: d1c88018a8e8e1bb5a2655728693909c3f616815203d9e0e202ae2f54f09a1b039ef031388528e99ed1dc348edc88ac48ec470416e7242939309cd0e19e94e98
7
+ data.tar.gz: c3571dc8a33345096cd024e390359ad28d06861f522f22d7c3b62070c8842e7379549eeff1f8ae8943e3289466c435fa3f87b1ba1bb84767f867a9066d7060f7
@@ -1,5 +1,10 @@
1
1
  # Fauxhai Changelog
2
2
 
3
+ ## v6.9.1 (2018-10-22)
4
+
5
+ - Remove extra 'etc' plugin data from several dumps
6
+ - Don't ship contributing and testing deps in the published gem to reduce gem size
7
+
3
8
  ## v6.9.0 (2018-10-20)
4
9
 
5
10
  ### New / Updated Platforms
@@ -14,9 +14,9 @@ Gem::Specification.new do |spec|
14
14
 
15
15
  spec.required_ruby_version = '>= 2.2.2'
16
16
 
17
- spec.files = `git ls-files -z`.split("\x0").reject { |f| f.match(%r{^(\..*|Gemfile|Rakefile)}) }
17
+ spec.files = `git ls-files -z`.split("\x0").reject { |f| f.match(%r{^(\..*|Gemfile|Rakefile|CONTRIBUTING.md|PLATFORMS.md|examples|spec)}) }
18
18
  spec.executables = spec.files.grep(%r{^bin/}).map { |f| File.basename(f) }
19
- spec.test_files = spec.files.grep(%r{^(test|spec|features)/})
19
+ spec.test_files = spec.files.grep(%r{^(test|spec)/})
20
20
  spec.require_paths = ['lib']
21
21
 
22
22
  spec.add_runtime_dependency 'net-ssh'
@@ -66,25 +66,6 @@
66
66
  "current_user": "fauxhai",
67
67
  "dmi": {},
68
68
  "domain": "local",
69
- "etc": {
70
- "group": {
71
- "fauxhai": {
72
- "gid": 0,
73
- "members": [
74
- "fauxhai"
75
- ]
76
- }
77
- },
78
- "passwd": {
79
- "fauxhai": {
80
- "dir": "/home/fauxhai",
81
- "gecos": "Fauxhai",
82
- "gid": 0,
83
- "shell": "/bin/bash",
84
- "uid": 0
85
- }
86
- }
87
- },
88
69
  "filesystem": {
89
70
  "Global:/": {
90
71
  "fs_type": "jfs2",
@@ -64,25 +64,6 @@
64
64
  "current_user": "fauxhai",
65
65
  "dmi": {},
66
66
  "domain": "local",
67
- "etc": {
68
- "group": {
69
- "fauxhai": {
70
- "gid": 0,
71
- "members": [
72
- "fauxhai"
73
- ]
74
- }
75
- },
76
- "passwd": {
77
- "fauxhai": {
78
- "dir": "/home/fauxhai",
79
- "gecos": "Fauxhai",
80
- "gid": 0,
81
- "shell": "/bin/bash",
82
- "uid": 0
83
- }
84
- }
85
- },
86
67
  "filesystem": {
87
68
  "C:": {
88
69
  "fs_type": "ntfs",
@@ -64,25 +64,6 @@
64
64
  "current_user": "fauxhai",
65
65
  "dmi": {},
66
66
  "domain": "local",
67
- "etc": {
68
- "group": {
69
- "fauxhai": {
70
- "gid": 0,
71
- "members": [
72
- "fauxhai"
73
- ]
74
- }
75
- },
76
- "passwd": {
77
- "fauxhai": {
78
- "dir": "/home/fauxhai",
79
- "gecos": "Fauxhai",
80
- "gid": 0,
81
- "shell": "/bin/bash",
82
- "uid": 0
83
- }
84
- }
85
- },
86
67
  "filesystem": {
87
68
  "C:": {
88
69
  "fs_type": "ntfs",
@@ -64,25 +64,6 @@
64
64
  "current_user": "fauxhai",
65
65
  "dmi": {},
66
66
  "domain": "local",
67
- "etc": {
68
- "group": {
69
- "fauxhai": {
70
- "gid": 0,
71
- "members": [
72
- "fauxhai"
73
- ]
74
- }
75
- },
76
- "passwd": {
77
- "fauxhai": {
78
- "dir": "/home/fauxhai",
79
- "gecos": "Fauxhai",
80
- "gid": 0,
81
- "shell": "/bin/bash",
82
- "uid": 0
83
- }
84
- }
85
- },
86
67
  "filesystem": {
87
68
  "C:": {
88
69
  "fs_type": "ntfs",
@@ -64,25 +64,6 @@
64
64
  "current_user": "fauxhai",
65
65
  "dmi": {},
66
66
  "domain": "local",
67
- "etc": {
68
- "group": {
69
- "fauxhai": {
70
- "gid": 0,
71
- "members": [
72
- "fauxhai"
73
- ]
74
- }
75
- },
76
- "passwd": {
77
- "fauxhai": {
78
- "dir": "/home/fauxhai",
79
- "gecos": "Fauxhai",
80
- "gid": 0,
81
- "shell": "/bin/bash",
82
- "uid": 0
83
- }
84
- }
85
- },
86
67
  "filesystem": {
87
68
  "C:": {
88
69
  "fs_type": "ntfs",
@@ -1,3 +1,3 @@
1
1
  module Fauxhai
2
- VERSION = '6.9.0'.freeze
2
+ VERSION = '6.9.1'.freeze
3
3
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: fauxhai
3
3
  version: !ruby/object:Gem::Version
4
- version: 6.9.0
4
+ version: 6.9.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - Seth Vargo
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2018-10-20 00:00:00.000000000 Z
11
+ date: 2018-10-23 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: net-ssh
@@ -103,13 +103,9 @@ extensions: []
103
103
  extra_rdoc_files: []
104
104
  files:
105
105
  - CHANGELOG.md
106
- - CONTRIBUTING.md
107
106
  - LICENSE
108
- - PLATFORMS.md
109
107
  - README.md
110
108
  - bin/fauxhai
111
- - examples/chefspec.md
112
- - examples/rspec-chef.md
113
109
  - fauxhai.gemspec
114
110
  - lib/fauxhai.rb
115
111
  - lib/fauxhai/exception.rb
@@ -229,8 +225,6 @@ files:
229
225
  - lib/fauxhai/runner/default.rb
230
226
  - lib/fauxhai/runner/windows.rb
231
227
  - lib/fauxhai/version.rb
232
- - spec/mocker_spec.rb
233
- - spec/spec_helper.rb
234
228
  - tmp/.gitkeep
235
229
  homepage: https://github.com/chefspec/fauxhai
236
230
  licenses:
@@ -257,6 +251,4 @@ signing_key:
257
251
  specification_version: 4
258
252
  summary: Fauxhai provides an easy way to mock out your ohai data for testing with
259
253
  chefspec!
260
- test_files:
261
- - spec/mocker_spec.rb
262
- - spec/spec_helper.rb
254
+ test_files: []
@@ -1,59 +0,0 @@
1
- # Contributing to Fauxhai
2
-
3
- Fauxhai is community-maintained and updated. Aside from the initial files, all of the ohai system mocks have been created by the community. If you have a system that you think would benefit the community, here's how you get it into [fauxhai](https://github.com/chefspec/fauxhai):
4
-
5
- 1. Build a system to your liking (on a virtual machine, for example)
6
- 2. Install chef, ohai, and fauxhai
7
- 3. Run the following at the command line:
8
-
9
- Unix:
10
-
11
- ```
12
- sudo fauxhai > /tmp/fauxhai.json
13
- ```
14
-
15
- Windows (in Administrator mode):
16
-
17
- ```
18
- fauxhai > C:\SomePath\fauxhai.json
19
- ```
20
-
21
- 4. This will create a file `fauxhai.json` at the specified path. As with any tool, inspect the contents of the file before continuing
22
-
23
- 5. Copy the contents of this file to your local development machine (using scp or sftp, for example)
24
- 6. Fork, clone and `bundle`:
25
-
26
- ```
27
- git clone https://github.com/<your username>/fauxhai.git
28
- cd fauxhai
29
- bundle
30
- ```
31
-
32
- 7. Create a new branch named `add_[platform]_[version]` (e.g. `add_ubuntu_12_04`) without dashes and dots replaced with underscores. Be sure to use the official version number, not a package name (e.g. '12_04', not 'precise') if available:
33
-
34
- ```
35
- Ubuntu Precise, 12.04 add_ubuntu_12_04
36
- Ubuntu Lucid, 10.04 add_ubuntu_10_04
37
- OSX Lion, 10.7.4 add_osx_10_7_4
38
- Windows XP add_windows_xp
39
- ```
40
-
41
- **Q:** Is there a reason for this super-specific naming convention?
42
-
43
- **A:** No, but it helps in tracking problems and analyzing pull requests. Ultimately it just ensures your pull request is merged as quickly as possible
44
-
45
- 8. Create a new json file in `lib/fauxhai/platforms/[os]/[version].json` (e.g. `lib/fauxhai/platforms/ubuntu/12.04.json`)
46
-
47
- 9. Copy-paste the contents of the file from `Step 4` into this file and save
48
- 10. Verify the installation was successful by doing the following:
49
-
50
- ```
51
- bundle console
52
- Fauxhai.mock(platform: '[os]', version: '[version]') # e.g. Fauxhai.mock(platform: 'ubuntu', version: '12.04')
53
- ```
54
-
55
- As long as that does not throw an error, you're good to go!
56
-
57
- 11. Submit a pull request on github
58
-
59
- **Note:** I do _not_ need to release a new version of Fauxhai for your changes to be pulled and used. Unless you are updating an existing platform, Fauxhai will automatically pull new versions from GitHub via HTTP and cache them.
@@ -1,141 +0,0 @@
1
- ## Fauxhai Platforms
2
-
3
- This file lists each platform known to Fauxhai and the available versions for each of those platforms. See the ChefSpec documentation for mocking out platforms and platform versions within ChefSpec.
4
-
5
- ### aix
6
-
7
- - 6.1
8
- - 7.1
9
-
10
- ### amazon
11
-
12
- - 2
13
- - 2015.03
14
- - 2015.09
15
- - 2016.03
16
- - 2016.09
17
- - 2017.03
18
- - 2017.09
19
- - 2018.03
20
-
21
- ### arch
22
-
23
- - 4.10.13-1-ARCH
24
-
25
- ### centos
26
-
27
- - 5.11
28
- - 6.8
29
- - 6.9
30
- - 7.3.1611
31
- - 7.4.1708
32
- - 7.5.1804
33
-
34
- ### clearos
35
-
36
- - 7.4
37
-
38
- ### debian
39
-
40
- - 7.11
41
- - 8.10
42
- - 8.11
43
- - 8.9
44
- - 9.2
45
- - 9.3
46
- - 9.4
47
- - 9.5
48
-
49
- ### dragonfly4
50
-
51
- - 4.8-RELEASE
52
-
53
- ### fedora
54
-
55
- - 26
56
- - 27
57
- - 28
58
-
59
- ### freebsd
60
-
61
- - 10.4
62
- - 11.1
63
- - 11.2
64
-
65
- ### gentoo
66
-
67
- - 4.9.95-gentoo
68
-
69
- ### linuxmint
70
-
71
- - 18.3
72
- - 19.0
73
-
74
- ### mac_os_x
75
-
76
- - 10.11
77
- - 10.12
78
- - 10.13
79
- - 10.14
80
-
81
- ### openbsd
82
-
83
- - 6.2
84
-
85
- ### opensuse
86
-
87
- - 42.2
88
- - 42.3
89
-
90
- ### oracle
91
-
92
- - 5.11
93
- - 6.8
94
- - 6.9
95
- - 7.3
96
- - 7.4
97
-
98
- ### raspbian
99
-
100
- - 8.0
101
-
102
- ### redhat
103
-
104
- - 5.11
105
- - 6.8
106
- - 6.9
107
- - 7.3
108
- - 7.4
109
- - 7.5
110
-
111
- ### smartos
112
-
113
- - 5.11
114
-
115
- ### solaris2
116
-
117
- - 5.11
118
-
119
- ### suse
120
-
121
- - 11.4
122
- - 12.1
123
- - 12.2
124
- - 12.3
125
- - 15
126
-
127
- ### ubuntu
128
-
129
- - 14.04
130
- - 16.04
131
- - 17.10
132
- - 18.04
133
-
134
- ### windows
135
-
136
- - 10
137
- - 2008R2
138
- - 2012
139
- - 2012R2
140
- - 2016
141
- - 8.1
@@ -1,68 +0,0 @@
1
- Fauxhai ChefSpec Examples
2
- =========================
3
-
4
- Mocking a Box
5
- -------------
6
- ```ruby
7
- require 'chefspec'
8
-
9
- describe 'awesome_cookbook::default' do
10
- before do
11
- Fauxhai.mock(platform:'ubuntu', version:'12.04')
12
- end
13
- end
14
- ```
15
-
16
- Mocking a Box with a Custom Ruby Version
17
- ----------------------------------------
18
- ```ruby
19
- require 'chefspec'
20
-
21
- describe 'awesome_cookbook::default' do
22
- before do
23
- Fauxhai.mock(platform:'ubuntu', version:'12.04') do |node|
24
- node['languages']['ruby']['version'] = 'ree'
25
- end
26
- end
27
- end
28
- ```
29
-
30
- Mocking a Box with Custom Hostname
31
- ----------------------------------
32
- ```ruby
33
- require 'chefspec'
34
-
35
- describe 'awesome_cookbook::default' do
36
- before do
37
- Fauxhai.mock(platform:'ubuntu', version:'12.04') do |node|
38
- node['hostname'] = 'server01.example.com'
39
- end
40
- end
41
- end
42
- ```
43
-
44
- Fetching a Remote Box
45
- ---------------------
46
- ```ruby
47
- require 'chefspec'
48
-
49
- describe 'awesome_cookbook::default' do
50
- before do
51
- Fauxhai.fetch(host:'server01.example.com')
52
- end
53
- end
54
- ```
55
-
56
- Fetching a Remote Box with custom Ruby Version
57
- ----------------------------------------------
58
- ```ruby
59
- require 'chefspec'
60
-
61
- describe 'awesome_cookbook::default' do
62
- before do
63
- Fauxhai.fetch(host:'server01.example.com') do |node|
64
- node['languages']['ruby']['version'] = 'ree'
65
- end
66
- end
67
- end
68
- ```
@@ -1,62 +0,0 @@
1
- Fauxhai Rspec-Chef Examples
2
- ===========================
3
-
4
- Mocking a Box
5
- -------------
6
- ```ruby
7
- describe 'foo::bar' do
8
- let(:json_attributes) { Fauxhai.mock(platform:'ubuntu', version:'12.04') }
9
- end
10
- ```
11
-
12
- Or as a default
13
- ```ruby
14
- # spec/spec_helper.rb
15
- RSpec.configure do |c|
16
- c.json_attributes = Fauxhai.mock(platform:'ubuntu', version:'12.04')
17
- end
18
- ```
19
-
20
- Mocking a Box with a Custom Ruby Version
21
- ----------------------------------------
22
- ```ruby
23
- describe 'foo::bar' do
24
- let(:json_attributes) do
25
- Fauxhai.mock(platform:'ubuntu', version:'12.04') do |node|
26
- node['languages']['ruby']['version'] = 'ree'
27
- end
28
- end
29
- end
30
- ```
31
-
32
- Mocking a Box with Custom Hostname
33
- ----------------------------------
34
- ```ruby
35
- describe 'foo::bar' do
36
- let(:json_attributes) do
37
- Fauxhai.mock(platform:'ubuntu', version:'12.04') do |node|
38
- node['hostname'] = 'server01.example.com'
39
- end
40
- end
41
- end
42
- ```
43
-
44
- Fetching a Remote Box
45
- ---------------------
46
- ```ruby
47
- describe 'foo::bar' do
48
- let(:json_attributes) { Fauxhai.fetch(host:'server01.example.com' }
49
- end
50
- ```
51
-
52
- Fetching a Remote Box with custom Ruby Version
53
- ----------------------------------------------
54
- ```ruby
55
- describe 'foo::bar' do
56
- let(:json_attributes) do
57
- Fauxhai.fetch(host:'server01.example.com') do |node|
58
- node['languages']['ruby']['version'] = 'ree'
59
- end
60
- end
61
- end
62
- ```
@@ -1,78 +0,0 @@
1
- require 'spec_helper'
2
-
3
- describe Fauxhai::Mocker do
4
- describe "#data" do
5
- let(:options) { {} }
6
- subject { described_class.new({github_fetching: false}.merge(options)).data }
7
-
8
- context 'with a platform and version' do
9
- let(:options) { {platform: 'chefspec', version: '0.6.1'} }
10
- its(['hostname']) { is_expected.to eq 'chefspec' }
11
- end
12
-
13
- context 'with a Windows platform and version' do
14
- let(:options) { {platform: 'windows', version: '10'} }
15
- its(['hostname']) { is_expected.to eq 'Fauxhai' }
16
- end
17
- end
18
-
19
- describe '#version' do
20
- let(:options) { {} }
21
- subject { described_class.new({github_fetching: false}.merge(options)).send(:version) }
22
-
23
- context 'with a platform and version' do
24
- let(:options) { {platform: 'chefspec', version: '0.6.1'} }
25
- it { is_expected.to eq '0.6.1' }
26
- end
27
-
28
- context 'with a platform and no version' do
29
- let(:options) { {platform: 'chefspec'} }
30
- it { is_expected.to eq '0.6.1' }
31
- end
32
-
33
- context 'with a platform and a blank version' do
34
- let(:options) { {platform: 'chefspec', version: ''} }
35
- it { is_expected.to eq '0.6.1' }
36
- end
37
-
38
- context 'with a platform and a partial version' do
39
- let(:options) { {platform: 'chefspec', version: '0.6'} }
40
- it { is_expected.to eq '0.6.1' }
41
- end
42
-
43
- context 'with a platform and a non-matching partial version' do
44
- let(:options) { {platform: 'chefspec', version: '0.7'} }
45
- it { is_expected.to eq '0.7' }
46
- end
47
-
48
- context 'with a Windows platform and no version' do
49
- let(:options) { {platform: 'windows'} }
50
- it { is_expected.to eq '2016' }
51
- end
52
-
53
- context 'with a Windows platform and a partial version' do
54
- let(:options) { {platform: 'windows', version: '2008'} }
55
- it { is_expected.to eq '2008R2' }
56
- end
57
-
58
- context 'with a Windows platform and an exact partial version' do
59
- let(:options) { {platform: 'windows', version: '2012'} }
60
- it { is_expected.to eq '2012' }
61
- end
62
-
63
- context 'with a CentOS platform and a partial version' do
64
- let(:options) { {platform: 'centos', version: '6'} }
65
- it { is_expected.to eq '6.9' }
66
- end
67
-
68
- context 'with a platform and an invalid version' do
69
- let(:options) { {platform: 'chefspec', version: '99'} }
70
- it { is_expected.to eq '99' }
71
- end
72
-
73
- context 'with an invalid platform and an invalid version' do
74
- let(:options) { {platform: 'notthere', version: '99'} }
75
- it { is_expected.to eq '99' }
76
- end
77
- end
78
- end
@@ -1,20 +0,0 @@
1
- require 'rspec'
2
- require 'rspec/its'
3
- require 'fauxhai'
4
-
5
- RSpec.configure do |config|
6
- # Basic configuraiton
7
- config.run_all_when_everything_filtered = true
8
- config.filter_run(:focus)
9
- config.add_formatter('documentation')
10
-
11
- # Run specs in random order to surface order dependencies. If you find an
12
- # order dependency and want to debug it, you can fix the order by providing
13
- # the seed, which is printed after each run.
14
- # --seed 1234
15
- config.order = 'random'
16
- config.seed = ENV['SEED'].to_i if ENV['SEED']
17
-
18
- # Enable full backtrace if $DEBUG is set.
19
- config.full_backtrace = true if ENV['DEBUG']
20
- end