Skip to content

Commit

Permalink
feat: パスを自動で解決できるようにする
Browse files Browse the repository at this point in the history
  • Loading branch information
xztaityozx committed Dec 2, 2023
1 parent a3db6ec commit 58e1efc
Showing 1 changed file with 7 additions and 1 deletion.
8 changes: 7 additions & 1 deletion test/e2e/test.ps1
Original file line number Diff line number Diff line change
Expand Up @@ -14,9 +14,15 @@ $tests = Get-ChildItem '0*' | ForEach-Object {
};
}

$selPath = if ( [System.IO.Path]::Exists("../../../dist/sel.exe") ) {
"../../../dist/sel.exe"
} else {
"../../../dist/sel"
}

Describe 'sel on PowerShell' {
It "sel -f <inputFile> <arguments> Returns <outputFile> (<name>)" -ForEach $tests {
$expected = Get-Content -Encoding utf8 $outputFile;
Invoke-Expression "Get-Content -Encoding utf8 $inputFile | ../../../dist/sel.exe $arguments" | Should -Be $expected;
Invoke-Expression "Get-Content -Encoding utf8 $inputFile | $selPath $arguments" | Should -Be $expected;
}
}

0 comments on commit 58e1efc

Please sign in to comment.