octopus-serverspec-extensions 0.13.4 → 0.13.5

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
  SHA1:
3
- metadata.gz: 0f662cbfa8fe9836cff3ad08990e804bc3aed47a
4
- data.tar.gz: 2f4206ce92f7f373bfe067861cf6989cec493b4d
3
+ metadata.gz: 9e22b8d434cb793ebc4f82f0824df31b239e109f
4
+ data.tar.gz: 9cc65067d6cccb05b71b6508b9cbfa92cb32fb7b
5
5
  SHA512:
6
- metadata.gz: 8e6999972e9ee4ae860e985a79cfdc147b4e32e35df4d4e2a1fdc1d256f2e8330e45d457df5ae7b3523bad6f4c00b7d7e777ea09b62de3ba1dd13d264674d097
7
- data.tar.gz: da6add0312507fd9c82404150b7614e6eebdeed745dcf95083771d60c55504a48997f56af5ace88deac3bf652b90614aebe96de9b76ca172a03afda609be081e
6
+ metadata.gz: 61860940e0f6959174a64240dfb6cee54d9cd9ce6c972f10499cf31b4749c9437d91f9bef69534f6a76080edeb4de8d3e6863e5052013ac3dc9e29ade1a3b0f1
7
+ data.tar.gz: ca6e1ec55aab6f065a9d99a609f37f937a7dac14a54072c5e2c85708ec0c325f93760298b4a49cdaa5a553f13677ef2384ddb4449d8caaaa99be07aa27395d52
@@ -9,12 +9,12 @@ module Serverspec::Type
9
9
  end
10
10
 
11
11
  def able_to_get_dsc_configuration?
12
- command_result = @runner.run_command('$ProgressPreference = "SilentlyContinue"; try { Get-DSCConfiguration -ErrorAction Stop; write-output "Get-DSCConfiguration succeeded"; $true } catch { write-output "Get-DSCConfiguration failed"; write-output $_; $false }')
12
+ command_result = @runner.run_command('$ProgressPreference = "SilentlyContinue"; $state = ""; do { $state = (Get-DscLocalConfigurationManager).LCMState; write-host "LCM state is $state"; Start-Sleep -Seconds 2; } while ($state -ne "Idle"); try { Get-DSCConfiguration -ErrorAction Stop; write-output "Get-DSCConfiguration succeeded"; $true } catch { write-output "Get-DSCConfiguration failed"; write-output $_; $false }')
13
13
  command_result.stdout.gsub(/\n/, '').match /Get-DSCConfiguration succeeded/
14
14
  end
15
15
 
16
16
  def applied_dsc_configuration_successfully?
17
- command_result = @runner.run_command('$ProgressPreference = "SilentlyContinue"; try { if (-not (Test-DSCConfiguration -ErrorAction Stop)) { write-output "Test-DSCConfiguration returned false"; exit 1 } write-output "Test-DSCConfiguration succeeded"; exit 0 } catch { write-output "Test-DSCConfiguration failed"; write-output $_; exit 2 }')
17
+ command_result = @runner.run_command('$ProgressPreference = "SilentlyContinue"; $state = ""; do { $state = (Get-DscLocalConfigurationManager).LCMState; write-host "LCM state is $state"; Start-Sleep -Seconds 2; } while ($state -ne "Idle"); try { if (-not (Test-DSCConfiguration -ErrorAction Stop)) { write-output "Test-DSCConfiguration returned false"; exit 1 } write-output "Test-DSCConfiguration succeeded"; exit 0 } catch { write-output "Test-DSCConfiguration failed"; write-output $_; exit 2 }')
18
18
  command_result.stdout.gsub(/\n/, '').match /Test-DSCConfiguration succeeded/
19
19
  end
20
20
 
@@ -1,3 +1,3 @@
1
1
  module OctopusServerSpecExtensions
2
- VERSION = "0.13.4"
2
+ VERSION = "0.13.5"
3
3
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: octopus-serverspec-extensions
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.13.4
4
+ version: 0.13.5
5
5
  platform: ruby
6
6
  authors:
7
7
  - Matt Richardson