chefspec 6.0.0 → 6.0.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
  SHA1:
3
- metadata.gz: c39538d26c07878521a8a68a1e8b488c80901e1d
4
- data.tar.gz: f95025605f2aaa4d047cb2f193fb6575e9e55144
3
+ metadata.gz: 0af3b0fac32c34603012d7eda57c92d51297c69a
4
+ data.tar.gz: fd3618c1325ea24de0e338c3aa571ca730cf06f2
5
5
  SHA512:
6
- metadata.gz: 24ca89915326c5474ed8802aa2d34c5777661e40d2cfcde76ada3ecf44f131968efd41a7c3f373ac41d4b6f6c0b8c4149b24adac82cd937b05541e80487d5a2d
7
- data.tar.gz: 15caa99f8225ec1f17186bab5d7b895a9a1febdec0c3bc050d2077da69948ef9827fcedd6c46d3812acc5a128bc22e099ae0f2a8fc450ab9308e93bcff272d75
6
+ metadata.gz: be88908f076438350c3ab3bf0d039449ae4005b2e7d72fb49eb6fc642d1400289eaf56c6de0d0fc00a9ced5f59ee9053d2c3e3034e0fb8b8d0bd35923bd2952d
7
+ data.tar.gz: f5fd03674808af2f1bab8b322adfe18723be83c8f0370774148717bb42fc43d0349b237f42be83e315f568975b4c1d405177750da4b3675d6712eb645ff671e9
@@ -1,5 +1,9 @@
1
1
  # CHANGELOG for ChefSpec
2
2
 
3
+ ## 6.0.1 (February 24, 2017)
4
+
5
+ - Add the ability to set the Chef Zero port range used by the ServerRunner
6
+
3
7
  ## 6.0.0 (February 22, 2017)
4
8
 
5
9
  BREAKING CHANGES
@@ -0,0 +1,17 @@
1
+ require 'chefspec'
2
+
3
+ describe 'server::port' do
4
+ let(:chef_run) do
5
+ ChefSpec::ServerRunner.new(platform: 'ubuntu', version: '16.04')
6
+ end
7
+
8
+ it 'does not raise an exception' do
9
+ expect { chef_run }.to_not raise_error
10
+ end
11
+
12
+ it 'creates a chef-zero listening on the right port' do
13
+ expect(ChefSpec::ZeroServer.server).to be_running?
14
+ expect(ChefSpec::ZeroServer.server.port).to be_a(Integer)
15
+ expect(8900..9010).to include(ChefSpec::ZeroServer.server.port)
16
+ end
17
+ end
@@ -0,0 +1,7 @@
1
+ Feature: The ChefSpec server with exotic port
2
+ Background:
3
+ * I am using the "server" cookbook
4
+
5
+ Scenario Outline: Running specs
6
+ * I successfully run `rspec spec/exotic_port_spec.rb --require ../../../features/support/exotic_zero_port.rb`
7
+ * the output should contain "0 failures"
@@ -0,0 +1,3 @@
1
+ RSpec.configure do |config|
2
+ config.server_runner_port = (8900..8910)
3
+ end
@@ -21,4 +21,5 @@ RSpec.configure do |config|
21
21
  config.add_setting :version
22
22
  config.add_setting :server_runner_data_store, default: :in_memory
23
23
  config.add_setting :server_runner_clear_cookbooks, default: true
24
+ config.add_setting :server_runner_port, default: (8889..8899)
24
25
  end
@@ -1,3 +1,3 @@
1
1
  module ChefSpec
2
- VERSION = '6.0.0'
2
+ VERSION = '6.0.1'
3
3
  end
@@ -16,6 +16,7 @@ module ChefSpec
16
16
  @server ||= ChefZero::Server.new(
17
17
  # Set the log level from RSpec, defaulting to warn
18
18
  log_level: RSpec.configuration.log_level || :warn,
19
+ port: RSpec.configuration.server_runner_port,
19
20
 
20
21
  # Set the data store
21
22
  data_store: data_store(RSpec.configuration.server_runner_data_store),
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: chefspec
3
3
  version: !ruby/object:Gem::Version
4
- version: 6.0.0
4
+ version: 6.0.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - Andrew Crump
@@ -9,7 +9,7 @@ authors:
9
9
  autorequire:
10
10
  bindir: bin
11
11
  cert_chain: []
12
- date: 2017-02-23 00:00:00.000000000 Z
12
+ date: 2017-02-24 00:00:00.000000000 Z
13
13
  dependencies:
14
14
  - !ruby/object:Gem::Dependency
15
15
  name: chef
@@ -528,6 +528,7 @@ files:
528
528
  - examples/server/spec/client_spec.rb
529
529
  - examples/server/spec/data_bag_spec.rb
530
530
  - examples/server/spec/environment_spec.rb
531
+ - examples/server/spec/exotic_port_spec.rb
531
532
  - examples/server/spec/node_spec.rb
532
533
  - examples/server/spec/render_with_cached_spec.rb
533
534
  - examples/server/spec/role_spec.rb
@@ -713,6 +714,7 @@ files:
713
714
  - features/env.feature
714
715
  - features/erl_call.feature
715
716
  - features/execute.feature
717
+ - features/exotic_zero_port.feature
716
718
  - features/expect_exception.feature
717
719
  - features/file.feature
718
720
  - features/freebsd_package.feature
@@ -771,6 +773,7 @@ files:
771
773
  - features/subversion.feature
772
774
  - features/support/env.rb
773
775
  - features/support/executor.rb
776
+ - features/support/exotic_zero_port.rb
774
777
  - features/support/on_disk.rb
775
778
  - features/systemd_unit.feature
776
779
  - features/template.feature
@@ -994,6 +997,7 @@ test_files:
994
997
  - features/env.feature
995
998
  - features/erl_call.feature
996
999
  - features/execute.feature
1000
+ - features/exotic_zero_port.feature
997
1001
  - features/expect_exception.feature
998
1002
  - features/file.feature
999
1003
  - features/freebsd_package.feature
@@ -1052,6 +1056,7 @@ test_files:
1052
1056
  - features/subversion.feature
1053
1057
  - features/support/env.rb
1054
1058
  - features/support/executor.rb
1059
+ - features/support/exotic_zero_port.rb
1055
1060
  - features/support/on_disk.rb
1056
1061
  - features/systemd_unit.feature
1057
1062
  - features/template.feature