Skip to content

Commit

Permalink
Style fixups
Browse files Browse the repository at this point in the history
  • Loading branch information
smira committed Jul 4, 2017
1 parent 211ac05 commit c13eb99
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 11 deletions.
2 changes: 0 additions & 2 deletions deb/reflist.go
Original file line number Diff line number Diff line change
Expand Up @@ -395,6 +395,4 @@ func (l *PackageRefList) FilterLatestRefs() {

lastArch, lastName, lastVer = arch, name, ver
}

return
}
2 changes: 1 addition & 1 deletion deb/remote.go
Original file line number Diff line number Diff line change
Expand Up @@ -198,7 +198,7 @@ func (repo *RemoteRepo) IndexesRootURL() *url.URL {
if !repo.IsFlat() {
path = &url.URL{Path: fmt.Sprintf("dists/%s/", repo.Distribution)}
} else {
path = &url.URL{Path: fmt.Sprintf("%s", repo.Distribution)}
path = &url.URL{Path: repo.Distribution}
}

return repo.archiveRootURL.ResolveReference(path)
Expand Down
12 changes: 4 additions & 8 deletions query/lex_test.go
Original file line number Diff line number Diff line change
@@ -1,10 +1,6 @@
package query

import (
"fmt"

. "gopkg.in/check.v1"
)
import . "gopkg.in/check.v1"

type LexerSuite struct {
}
Expand Down Expand Up @@ -46,13 +42,13 @@ func (s *LexerSuite) TestConsume(c *C) {
func (s *LexerSuite) TestString(c *C) {
l, _ := lex("query", "package (<< 1.3)")

c.Check(fmt.Sprintf("%s", l.Current()), Equals, "\"package\"")
c.Check(l.Current().String(), Equals, "\"package\"")
l.Consume()
c.Check(fmt.Sprintf("%s", l.Current()), Equals, "(")
c.Check(l.Current().String(), Equals, "(")
}

func (s *LexerSuite) TestError(c *C) {
l, _ := lex("query", "'package")

c.Check(fmt.Sprintf("%s", l.Current()), Equals, "error: unexpected eof in quoted string")
c.Check(l.Current().String(), Equals, "error: unexpected eof in quoted string")
}

0 comments on commit c13eb99

Please sign in to comment.