You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

20 lines
531 B

9 years ago
  1. // Copyright 2015 The Gogs Authors. All rights reserved.
  2. // Use of this source code is governed by a MIT-style
  3. // license that can be found in the LICENSE file.
  4. package git
  5. import (
  6. "testing"
  7. . "github.com/smartystreets/goconvey/convey"
  8. )
  9. func Test_newSignatureFromCommitline(t *testing.T) {
  10. Convey("Parse signature from commit line", t, func() {
  11. line := "Intern <intern@macbook-intern.(none)> 1445412825 +0200"
  12. sig, err := newSignatureFromCommitline([]byte(line))
  13. So(err, ShouldBeNil)
  14. So(sig, ShouldNotBeNil)
  15. })
  16. }