Skip to content

Commit

Permalink
Update tests for OpenBSD tar output
Browse files Browse the repository at this point in the history
  • Loading branch information
twpayne committed Aug 29, 2021
1 parent 0d82773 commit 2cec38f
Show file tree
Hide file tree
Showing 4 changed files with 7 additions and 0 deletions.
2 changes: 2 additions & 0 deletions internal/cmd/main_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -71,6 +71,8 @@ func TestScript(t *testing.T) {
return runtime.GOOS == "freebsd", nil
case "linux":
return runtime.GOOS == "linux", nil
case "openbsd":
return runtime.GOOS == "openbsd", nil
case "windows":
return runtime.GOOS == "windows", nil
}
Expand Down
1 change: 1 addition & 0 deletions internal/cmd/testdata/scripts/archivetar.txt
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
mksourcedir

[openbsd] exec sed -e 's:/$::g' -i golden/archive-tar
[windows] unix2dos golden/archive-tar

chezmoi archive --output=archive.tar
Expand Down
2 changes: 2 additions & 0 deletions internal/cmd/testdata/scripts/runscriptdir_unix.txt
Original file line number Diff line number Diff line change
@@ -1,6 +1,8 @@
[windows] skip 'UNIX only'
[!umask:022] skip

[openbsd] exec sed -e 's:/$::g' -i golden/archive

chezmoi apply
cmpenv stdout golden/apply

Expand Down
2 changes: 2 additions & 0 deletions internal/cmd/testdata/scripts/scriptsubdir_unix.txt
Original file line number Diff line number Diff line change
@@ -1,6 +1,8 @@
[windows] skip 'UNIX only'
[!umask:022] skip

[openbsd] exec sed -e 's:/$::g' -i golden/archive

# test that scripts in subdirectories are run in the subdirectory
chezmoi apply --force
cmpenv stdout golden/apply
Expand Down

0 comments on commit 2cec38f

Please sign in to comment.