Files
PowerShell/test/powershell/Host/PSVersionTable.Tests.ps1
T

25 lines
1.1 KiB
PowerShell
Raw Normal View History

2016-07-25 14:01:41 -07:00
Describe "PSVersionTable" -Tags "CI" {
2015-07-20 17:18:06 -07:00
It "Should have version table entries" {
$PSVersionTable.Count | Should Be 9
2015-07-20 17:18:06 -07:00
}
It "Should have the right version table entries" {
$PSVersionTable.ContainsKey("PSVersion") | Should Be True
$PSVersionTable.ContainsKey("PSEdition") | Should Be True
$PSVersionTable.ContainsKey("WSManStackVersion") | Should Be True
$PSVersionTable.ContainsKey("SerializationVersion") | Should Be True
$PSVersionTable.ContainsKey("CLRVersion") | Should Be True
$PSVersionTable.ContainsKey("BuildVersion") | Should Be True
$PSVersionTable.ContainsKey("PSCompatibleVersions") | Should Be True
$PSVersionTable.ContainsKey("PSRemotingProtocolVersion") | Should Be True
$PSVersionTable.ContainsKey("GitCommitId") | Should Be True
2015-07-20 17:18:06 -07:00
}
It "GitCommitId property should not contain an error" {
$PSVersionTable.GitCommitId | Should not match "powershell.version"
}
2016-03-04 14:40:33 -08:00
2016-07-21 16:52:22 -07:00
It "Should have the correct edition" -Skip:(!$IsCoreCLR) {
$PSVersionTable["PSEdition"] | Should Be "Core"
2016-03-04 14:40:33 -08:00
}
2015-07-20 17:18:06 -07:00
}