mirror of
https://github.com/aphrody-labs/PowerShell.git
synced 2026-10-17 12:45:47 +00:00
Programmatic indentation and whitespace-cleanup of tests
This commit is contained in:
1 parent
0aaf74bdcc
commit
0c6b14adab
83 files changed
+2191
-2193
No files matched your search
@@ -3,23 +3,23 @@ Describe "DotNetAPI" {
|
||||
$posh_pi = 3.14159265358979
|
||||
|
||||
It "Should be able to use static .NET classes and get a constant" {
|
||||
[System.Math]::E | Should Match $posh_E.ToString()
|
||||
[System.Math]::PI | Should Match $posh_pi.ToString()
|
||||
[System.Math]::E | Should Match $posh_E.ToString()
|
||||
[System.Math]::PI | Should Match $posh_pi.ToString()
|
||||
}
|
||||
|
||||
It "Should be able to invoke a method" {
|
||||
[System.Environment]::GetEnvironmentVariable("PATH") | Should Be $env:PATH
|
||||
[System.Environment]::GetEnvironmentVariable("PATH") | Should Be $env:PATH
|
||||
}
|
||||
|
||||
It "Should not require 'system' in front of static classes" {
|
||||
[Environment]::CommandLine | Should Be ([System.Environment]::CommandLine)
|
||||
[Environment]::CommandLine | Should Be ([System.Environment]::CommandLine)
|
||||
|
||||
[Math]::E | Should Be ([System.Math]::E)
|
||||
[Math]::E | Should Be ([System.Math]::E)
|
||||
}
|
||||
|
||||
It "Should be able to create a new instance of a .Net object" {
|
||||
[System.Guid]$guidVal = [System.Guid]::NewGuid()
|
||||
[System.Guid]$guidVal = [System.Guid]::NewGuid()
|
||||
|
||||
$guidVal.GetType().Name | Should Be "Guid"
|
||||
$guidVal.GetType().Name | Should Be "Guid"
|
||||
}
|
||||
}
|
||||
Reference in new issue
Block a user