Skip to content

Commit

Permalink
Some path fixes for unix
Browse files Browse the repository at this point in the history
  • Loading branch information
Richard Kuhnt committed May 27, 2017
1 parent 59139ba commit 5b4b2fc
Show file tree
Hide file tree
Showing 4 changed files with 5 additions and 4 deletions.
1 change: 1 addition & 0 deletions lib/core.ps1
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,7 @@ if(isUnix) {
$scoopdir = $env:SCOOP, (Join-Path $env:HOME "scoop") | select -first 1
$globaldir = $env:SCOOP_GLOBAL, "/usr/local/scoop" | select -first 1
$cachedir = $env:SCOOP_CACHE, (Join-Path $scoopdir "cache") | select -first 1
$env:TEMP = "/tmp"
}

# helper functions
Expand Down
4 changes: 2 additions & 2 deletions test/00-Project.Tests.ps1
Original file line number Diff line number Diff line change
Expand Up @@ -3,9 +3,9 @@ $repo_dir = (Get-Item $MyInvocation.MyCommand.Path).directory.parent.FullName
$repo_files = @( Get-ChildItem $repo_dir -file -recurse -force )

$project_file_exclusions = @(
$([regex]::Escape($repo_dir)+'\\.git\\.*$'),
$([regex]::Escape($repo_dir)+'(\\|/).git(\\|/).*$'),
'.sublime-workspace$',
'supporting\\validator\\packages\\*'
'supporting(\\|/)validator(\\|/)packages(\\|/)*'
)

describe 'Project code' {
Expand Down
2 changes: 1 addition & 1 deletion test/Scoop-Manifest.Tests.ps1
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
describe "manifest-validation" {
beforeall {
$working_dir = setup_working "manifest"
$schema = "$psscriptroot\..\schema.json"
$schema = "$psscriptroot/../schema.json"
Add-Type -Path "$psscriptroot\..\supporting\validator\Newtonsoft.Json.dll"
Add-Type -Path "$psscriptroot\..\supporting\validator\Newtonsoft.Json.Schema.dll"
Add-Type -Path "$psscriptroot\..\supporting\validator\Scoop.Validator.dll"
Expand Down
2 changes: 1 addition & 1 deletion test/Scoop-TestLib.ps1
Original file line number Diff line number Diff line change
Expand Up @@ -73,7 +73,7 @@ function setup_working($name) {
}

# reset working dir
$working_dir = "$env:temp\ScoopTestFixtures\$name"
$working_dir = "$env:TEMP\ScoopTestFixtures\$name"
if(test-path $working_dir) {
Remove-Item -Recurse -Force $working_dir
}
Expand Down

0 comments on commit 5b4b2fc

Please sign in to comment.