Skip to content

Commit

Permalink
Test fix
Browse files Browse the repository at this point in the history
  • Loading branch information
kosticmarin committed Aug 22, 2023
1 parent 31df311 commit 49e9c9c
Show file tree
Hide file tree
Showing 4 changed files with 13 additions and 11 deletions.
1 change: 1 addition & 0 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,7 @@ jobs:
shellcheck -s sh *.sh
- name: tests shell
if: matrix.os != 'windows-latest'
shell: bash
run: ./install_test.sh

Expand Down
2 changes: 2 additions & 0 deletions install.ps1
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,8 @@ if ($Args.Length -eq 1) {
}

$LunaticInstall = $env::LUNATIC_INSTALL
Write-Output "HELLO WORLD ${LunaticInstall}"

$BinDir = if ($LunaticInstall) {
"${LunaticInstall}\bin"
} else {
Expand Down
3 changes: 1 addition & 2 deletions install.sh
Original file line number Diff line number Diff line change
Expand Up @@ -8,8 +8,7 @@ if ! command -v tar >/dev/null; then
fi

if [ "$OS" = "Windows_NT" ]; then
echo "Error: Official Lunatic Runtime builds for Windows NT are not available." 1>&2
exit 1
target="windows-amd64"
else
case $(uname -sm) in
"Darwin") target="macos-universal" ;;
Expand Down
18 changes: 9 additions & 9 deletions install_test.ps1
Original file line number Diff line number Diff line change
Expand Up @@ -12,25 +12,25 @@ $v = $null; .\install.ps1
Remove-Item "~\lunatic-0.12.0" -Recurse -Force -ErrorAction SilentlyContinue
$env:LUNATIC_INSTALL = "$Home\lunatic-0.12.0"
$v = "0.12.0"; .\install.ps1
$lunaticVersion = ~\lunatic-0.12.0\bin\lunatic.exe --version
if (!($lunaticVersion -like '*0.12.0*')) {
throw $lunaticVersion
$LunaticVersion = ~\lunatic-0.12.0\bin\lunatic.exe --version
if (!($LunaticVersion -like '*0.12.0*')) {
throw $LunaticVersion
}

# Test that we can install at a relative custom location.
Remove-Item "bin" -Recurse -Force -ErrorAction SilentlyContinue
$env:LUNATIC_INSTALL = "."
$v = "0.12.0"; .\install.ps1
$lunaticVersion = bin\lunatic.exe --version
if (!($lunaticVersion -like '*0.12.0*')) {
throw $lunaticVersion
$LunaticVersion = bin\lunatic.exe --version
if (!($LunaticVersion -like '*0.12.0*')) {
throw $LunaticVersion
}

# Test that the old temp file installer still works.
Remove-Item "~\lunatic-0.12.0" -Recurse -Force -ErrorAction SilentlyContinue
$env:LUNATIC_INSTALL = "$Home\lunatic-0.12.0"
$v = $null; .\install.ps1 v0.12.0
$lunaticVersion = ~\lunatic-0.12.0\bin\lunatic.exe --version
if (!($lunaticVersion -like '*0.12.0*')) {
throw $lunaticVersion
$LunaticVersion = ~\lunatic-0.12.0\bin\lunatic.exe --version
if (!($LunaticVersion -like '*0.12.0*')) {
throw $LunaticVersion
}

0 comments on commit 49e9c9c

Please sign in to comment.