File tree Expand file tree Collapse file tree 5 files changed +9
-10
lines changed
Expand file tree Collapse file tree 5 files changed +9
-10
lines changed Original file line number Diff line number Diff line change @@ -31,7 +31,7 @@ Describe "BOSH.Account" {
3131 }
3232
3333 BeforeEach {
34- $userExists = !! (Get-LocalUser | Where { $_.Name -eq $user })
34+ $userExists = !! (Get-LocalUser | Where-Object { $_.Name -eq $user })
3535 if ($userExists )
3636 {
3737 Remove-LocalUser - Name $user
Original file line number Diff line number Diff line change @@ -43,7 +43,7 @@ Describe "BOSH.CFCell" {
4343
4444 Protect-CFCell - IaaS " ignored"
4545
46- Get-ItemProperty - Path " HKLM:\System\CurrentControlSet\Control\Terminal Server" | select - exp fDenyTSConnections | Should - Be 1
46+ Get-ItemProperty - Path " HKLM:\System\CurrentControlSet\Control\Terminal Server" | Select-Object - exp fDenyTSConnections | Should - Be 1
4747 netstat / p tcp / a | findstr " :3389 " | Should - BeNullOrEmpty
4848 Get-NetFirewallRule - DisplayName " Remote Desktop*" | ForEach-Object { $_.enabled | Should - Be " False" }
4949 Get-Service " Termservice" | Select-Object - exp starttype | Should - Be " Disabled"
Original file line number Diff line number Diff line change @@ -52,9 +52,9 @@ BeforeAll {
5252
5353 mkdir " $dir \OpenSSH-Win64"
5454 $installSpyBehavior = " echo installed > $installScriptSpyStatus "
55- echo $installSpyBehavior > " $dir \OpenSSH-Win64\install-sshd.ps1"
56- echo " fake sshd" > " $dir \OpenSSH-Win64\sshd.exe"
57- echo " fake config" > " $dir \OpenSSH-Win64\sshd_config_default"
55+ Write-Output $installSpyBehavior > " $dir \OpenSSH-Win64\install-sshd.ps1"
56+ Write-Output " fake sshd" > " $dir \OpenSSH-Win64\sshd.exe"
57+ Write-Output " fake config" > " $dir \OpenSSH-Win64\sshd_config_default"
5858
5959 Compress-Archive - Force - Path " $dir \OpenSSH-Win64" - DestinationPath $fakeZipPath
6060 }
@@ -79,7 +79,7 @@ Describe "BOSH.SSH" {
7979 CreateFakeOpenSSHZip - dir $TMP_DIR - installScriptSpyStatus $INSTALL_SCRIPT_SPY_STATUS - fakeZipPath $FAKE_ZIP
8080
8181 mkdir - p " $TMP_DIR \Windows\Temp"
82- echo " fake LGPO" > " $TMP_DIR \Windows\LGPO.exe"
82+ Write-Output " fake LGPO" > " $TMP_DIR \Windows\LGPO.exe"
8383
8484 $ORIGINAL_WINDIR = $env: WINDIR
8585 $env: WINDIR = " $TMP_DIR \Windows"
Original file line number Diff line number Diff line change @@ -17,11 +17,11 @@ def self.from_string(s)
1717 AuditFile . new ( header , contents )
1818 end
1919
20- def print ( )
20+ def print
2121 ( [ header ] + contents ) . join ( "\r \n " )
2222 end
2323
24- def uniq ( )
24+ def uniq
2525 uniqed = contents . uniq do |x |
2626 values = x . split ( ',' )
2727 keys = values [ 0 ..5 ] . join ( '' ) . downcase
@@ -32,7 +32,7 @@ def uniq()
3232 AuditFile . new ( header , uniqed )
3333 end
3434
35- def size ( )
35+ def size
3636 contents . size
3737 end
3838end
Original file line number Diff line number Diff line change @@ -101,7 +101,6 @@ function Install-WindowsUpdates
101101
102102function Invoke-RebootOrComplete
103103{
104- $RegistryEntry = " InstallWindowsUpdates"
105104 switch ($script :RestartRequired )
106105 {
107106 0 {
You can’t perform that action at this time.
0 commit comments