Skip to content

Commit

Permalink
Enable Windows on CI
Browse files Browse the repository at this point in the history
This ensures that the package compiles on Windows, and that ErrNotSupported is returned.
We need to remove testing on Go master, since this is currently broken on Travis. Testing
master doesn't make much sense in the first place.
  • Loading branch information
lmb committed Apr 28, 2020
1 parent da237db commit ea2ef0d
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 1 deletion.
2 changes: 1 addition & 1 deletion .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,8 +3,8 @@ language: go
go:
- "1.13.x"
- "1.14.x"
- master

os:
- linux
- osx
- windows
4 changes: 4 additions & 0 deletions upgrader_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -64,6 +64,10 @@ var names = []string{"zaphod", "beeblebrox"}

func TestMain(m *testing.M) {
upg, err := New(Options{})
if errors.Is(err, ErrNotSupported) {
fmt.Fprintln(os.Stderr, "Skipping tests, OS is not supported")
os.Exit(0)
}
if err != nil {
panic(err)
}
Expand Down

0 comments on commit ea2ef0d

Please sign in to comment.