Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Support go 1.15 #434

Merged
merged 1 commit into from
Sep 11, 2020
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
40 changes: 20 additions & 20 deletions azure-pipelines.yml
Original file line number Diff line number Diff line change
Expand Up @@ -13,9 +13,9 @@ stages:
vmImage: ubuntu-latest
steps:
- task: GoTool@0
displayName: "Install Go 1.14"
displayName: "Install Go 1.15"
inputs:
version: "1.14"
version: "1.15"
- script: echo "##vso[task.setvariable variable=PATH]${PATH}:/home/vsts/go/bin/"
- script: mkdir -p ${HOME}/go/src/github.com/pelletier/go-toml
- script: cp -R . ${HOME}/go/src/github.com/pelletier/go-toml
Expand All @@ -36,9 +36,9 @@ stages:
vmImage: ubuntu-latest
steps:
- task: GoTool@0
displayName: "Install Go 1.14"
displayName: "Install Go 1.15"
inputs:
version: "1.14"
version: "1.15"
- task: Go@0
displayName: "go fmt ./..."
inputs:
Expand All @@ -51,9 +51,9 @@ stages:
vmImage: ubuntu-latest
steps:
- task: GoTool@0
displayName: "Install Go 1.14"
displayName: "Install Go 1.15"
inputs:
version: "1.14"
version: "1.15"
- task: Go@0
displayName: "Generate coverage"
inputs:
Expand All @@ -71,9 +71,9 @@ stages:
vmImage: ubuntu-latest
steps:
- task: GoTool@0
displayName: "Install Go 1.14"
displayName: "Install Go 1.15"
inputs:
version: "1.14"
version: "1.15"
- script: echo "##vso[task.setvariable variable=PATH]${PATH}:/home/vsts/go/bin/"
- task: Bash@3
inputs:
Expand All @@ -86,9 +86,9 @@ stages:
vmImage: ubuntu-latest
steps:
- task: GoTool@0
displayName: "Install Go 1.14"
displayName: "Install Go 1.15"
inputs:
version: "1.14"
version: "1.15"
- script: echo "##vso[task.setvariable variable=PATH]${PATH}:/home/vsts/go/bin/"
- script: mkdir -p ${HOME}/go/src/github.com/pelletier/go-toml
- script: cp -R . ${HOME}/go/src/github.com/pelletier/go-toml
Expand All @@ -102,6 +102,15 @@ stages:
displayName: "unit tests"
strategy:
matrix:
linux 1.15:
goVersion: '1.15'
imageName: 'ubuntu-latest'
mac 1.15:
goVersion: '1.15'
imageName: 'macOS-latest'
windows 1.15:
goVersion: '1.15'
imageName: 'windows-latest'
linux 1.14:
goVersion: '1.14'
imageName: 'ubuntu-latest'
Expand All @@ -111,15 +120,6 @@ stages:
windows 1.14:
goVersion: '1.14'
imageName: 'windows-latest'
linux 1.13:
goVersion: '1.13'
imageName: 'ubuntu-latest'
mac 1.13:
goVersion: '1.13'
imageName: 'macOS-latest'
windows 1.13:
goVersion: '1.13'
imageName: 'windows-latest'
pool:
vmImage: $(imageName)
steps:
Expand Down Expand Up @@ -155,7 +155,7 @@ stages:
- task: GoTool@0
displayName: "Install Go"
inputs:
version: 1.14
version: 1.15
- task: Bash@3
inputs:
targetType: inline
Expand Down
5 changes: 1 addition & 4 deletions marshal_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -2194,10 +2194,7 @@ func TestUnmarshalBadDuration(t *testing.T) {
result := testBadDuration{}
err := NewDecoder(buf).Decode(&result)
if err == nil {
t.Fatal()
}
if err.Error() != "(1, 1): Can't convert 1z(string) to time.Duration. time: unknown unit z in duration 1z" {
t.Fatalf("unexpected error: %s", err)
t.Fatal("expected bad duration error")
}
}

Expand Down