Files
PowerShell/test/powershell/Import-Alias.Tests.ps1
T

25 lines
856 B
PowerShell
Raw Normal View History

2015-11-19 06:21:35 +00:00
Describe "Import-Alias" {
$pesteraliasfile = Join-Path -Path (Join-Path $PSScriptRoot -ChildPath assets) -ChildPath pesteralias.txt
2015-11-19 06:21:35 +00:00
Context "Validate ability to import alias file" {
It "Should be able to import an alias file successfully" {
{ Import-Alias $pesteraliasfile } | Should Not throw
2015-11-19 06:21:35 +00:00
}
It "Should be able to import file via the Import-Alias alias of ipal" {
{ ipal $pesteraliasfile } | Should Not throw
}
It "Should be able to import an alias file and perform imported aliased echo cmd" {
(Import-Alias $pesteraliasfile)
(pesterecho pestertesting) | Should Be "pestertesting"
}
It "Should be able to use ipal alias to import an alias file and perform cmd" {
(ipal $pesteraliasfile)
(pesterecho pestertesting) | Should be "pestertesting"
}
}
}