Skip to content
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
Show all changes
21 commits
Select commit Hold shift + click to select a range
ea4e2d2
[Feature]Added BinPath, Description, UserName and Delayed Auto Start …
joandrsn Sep 23, 2017
d3f64b1
[Feature]StartupType added with support for automatic delayed start o…
joandrsn Sep 24, 2017
58b1303
[Feature]StartupType reverted back from a public property
joandrsn Sep 25, 2017
fa97af5
[Feature]Corrected error written if delayed auto start boolean could …
joandrsn Sep 25, 2017
29ce383
[Feature]Corrected the exception message to be thrown where it was ac…
joandrsn Sep 25, 2017
b758abe
[Feature]Correct tests for linux and osx.
joandrsn Sep 25, 2017
5101150
[Feature]Freed the memory after using pointers. Corrected documentati…
joandrsn Sep 30, 2017
e6a56f9
[Feature]Use the corrrect dereferencing method when freeing pointers
joandrsn Sep 30, 2017
175897a
[Feature]Changed to AllocCoTaskMem when reserving memory
joandrsn Oct 1, 2017
b4b06da
[Feature]Corrected formatting
joandrsn Oct 2, 2017
51930c9
[Feature]Added spaces before IsWindow check
joandrsn Oct 2, 2017
17922cf
[Feature]Corrected indention in test
joandrsn Oct 2, 2017
1eef742
[Feature]Renamed variable names for readability and consistency.
joandrsn Oct 2, 2017
d3c818c
[Feature]Moved FreeCoTaskMem to finally block on New-Service and Set-…
joandrsn Oct 3, 2017
a8120ea
[Feature]Remove FreeCoTaskMem(buffer) as the variable was renamed and…
joandrsn Oct 3, 2017
9e4bf0c
[Feature]Made generic function to query for service information.
joandrsn Oct 18, 2017
de135ba
Merged changes made to master since original pull request
joandrsn Oct 18, 2017
9e2ddb3
[Feature]Corrected indention
joandrsn Oct 18, 2017
755e192
[Feature]Corrected error message to refence the new name
joandrsn Oct 19, 2017
791cfea
Merge branch 'master' of https://github.com/PowerShell/PowerShell int…
joandrsn Oct 20, 2017
a9a2b32
[Feature]Corrected missed merge errors and made a InvalidValue Servic…
joandrsn Oct 20, 2017
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
[Feature]Corrected formatting
  • Loading branch information
joandrsn committed Oct 2, 2017
commit b4b06da4e0879c1e7e550bf15043693ca2101f76
Original file line number Diff line number Diff line change
Expand Up @@ -2917,7 +2917,7 @@ internal static ServiceStartupType GetServiceStartupType(ServiceStartMode startM

#region ServiceStartupType
///<summary>
///Enum for usage with StartupType. Automatic, Manual & Disabled index matched from System.ServiceProcess.ServiceStartMode
///Enum for usage with StartupType. Automatic, Manual and Disabled index matched from System.ServiceProcess.ServiceStartMode
///</summary>
public enum ServiceStartupType {
///<summary>Automatic service</summary>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -5,17 +5,17 @@ Describe "Set/New/Remove-Service cmdlet tests" -Tags "Feature", "RequireAdminOnW
$PSDefaultParameterValues["it:skip"] = $true
}
if($IsWindows) {
Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please add spaces - use common formatting convention. Below too.

$userName = "testuserservices"
$testPass = "Secret123!"
net user $userName $testPass /add > $null
$password = ConvertTo-SecureString $testPass -AsPlainText -Force
$creds = [pscredential]::new(".\$userName", $password)
$userName = "testuserservices"
$testPass = "Secret123!"
net user $userName $testPass /add > $null
$password = ConvertTo-SecureString $testPass -AsPlainText -Force
$creds = [pscredential]::new(".\$userName", $password)
}
}
AfterAll {
$global:PSDefaultParameterValues = $originalDefaultParameterValues
if($IsWindows) {
net user $userName /delete > $null
net user $userName /delete > $null
}
}

Expand Down Expand Up @@ -241,7 +241,7 @@ Describe "Set/New/Remove-Service cmdlet tests" -Tags "Feature", "RequireAdminOnW
{ Remove-Service -Name "testremoveservice" -ErrorAction 'Stop' } | ShouldBeErrorId "InvalidOperationException,Microsoft.PowerShell.Commands.RemoveServiceCommand"
}

It "Get-Service can get the '<property>' of a service" -TestCases @(
It "Get-Service can get the '<property>' of a service" -TestCases @(
Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please correct indentation in the test.

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Closed.

@{property = "Description"; value = "This is a test description"}
@{property = "BinPath"; value = "$PSHOME\powershell.exe"; parameters = @{ BinaryPathName = "$PSHOME\powershell.exe" }},
@{property = "UserName"; value = $creds.UserName; parameters = @{ Credential = $creds }},
Expand Down