diff --git a/src/github.com/matrix-org/go-neb/services/travisci/travisci.go b/src/github.com/matrix-org/go-neb/services/travisci/travisci.go index 5f2392d..716bcbd 100644 --- a/src/github.com/matrix-org/go-neb/services/travisci/travisci.go +++ b/src/github.com/matrix-org/go-neb/services/travisci/travisci.go @@ -133,9 +133,9 @@ func notifToTemplate(n webhookNotification) map[string]string { if n.StartedAt != nil && n.FinishedAt != nil { // duration: total duration of all builds in the matrix -- TODO // elapsed_time: time between build start and finish - // Example from docs: "2011-11-11T11: 11: 11Z" - start, err := time.Parse("2006-01-02T15: 04: 05Z", *n.StartedAt) - finish, err2 := time.Parse("2006-01-02T15: 04: 05Z", *n.FinishedAt) + // Example from docs: "2011-11-11T11:11:11Z" + start, err := time.Parse("2006-01-02T15:04:05Z", *n.StartedAt) + finish, err2 := time.Parse("2006-01-02T15:04:05Z", *n.FinishedAt) if err != nil || err2 != nil { log.WithFields(log.Fields{ "started_at": *n.StartedAt, diff --git a/src/github.com/matrix-org/go-neb/services/travisci/travisci_test.go b/src/github.com/matrix-org/go-neb/services/travisci/travisci_test.go index 81d17b7..f2527c3 100644 --- a/src/github.com/matrix-org/go-neb/services/travisci/travisci_test.go +++ b/src/github.com/matrix-org/go-neb/services/travisci/travisci_test.go @@ -84,6 +84,11 @@ var travisTests = []struct { "%{repository}#%{build_number} (%{branch} - %{commit} : %{author}): %{message}", "Kegsay/flow-jsdoc#18 (master - 3a092c3a6032ebb50384c99b445f947e9ce86e2a : Kegan Dougal): Passed", }, + { + exampleSignature, true, exampleBody, + "%{repository}#%{build_number} %{duration}", + "Kegsay/flow-jsdoc#18 32s", + }, } type MockTransport struct {