mirror of
https://github.com/ScoopInstaller/Scoop.git
synced 2026-08-29 17:46:44 +00:00
Migrate unzip_old tests to pester Migrate packages tests to Pester Migrate opts.ps1 to Pester Migrate tests to use Pester idiomatic tests Move tests.ps1 to Scoop-TestLib.ps1
21 lines
458 B
PowerShell
21 lines
458 B
PowerShell
. "$psscriptroot\Scoop-TestLib.ps1"
|
|
. "$psscriptroot\..\lib\versions.ps1"
|
|
|
|
describe "versions" {
|
|
it 'compares versions with integer-string mismatch' {
|
|
$a = '1.8.9'
|
|
$b = '1.8.5-1'
|
|
$res = compare_versions $a $b
|
|
|
|
$res | should be 1
|
|
}
|
|
|
|
it 'handles plain string version comparison to int version' {
|
|
$a = 'latest'
|
|
$b = '20150405'
|
|
$res = compare_versions $a $b
|
|
|
|
$res | should be 1
|
|
}
|
|
}
|