Skip to content

Commit

Permalink
Merge pull request russross#18 from dannyvankooten/formatting-directives
Browse files Browse the repository at this point in the history
use correct fmt directives for int types
  • Loading branch information
russross authored Mar 19, 2017
2 parents f742b0f + 6ad6e07 commit 6a044b2
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 3 deletions.
2 changes: 1 addition & 1 deletion scan.go
Original file line number Diff line number Diff line change
Expand Up @@ -434,7 +434,7 @@ func Targets(dst interface{}, columns []string) ([]interface{}, error) {
// by Targets.
func (d *Database) WriteTargets(dst interface{}, columns []string, targets []interface{}) error {
if len(columns) != len(targets) {
return fmt.Errorf("meddler.WriteTargets: mismatch in number of columns (%d) and targets (%s)",
return fmt.Errorf("meddler.WriteTargets: mismatch in number of columns (%d) and targets (%d)",
len(columns), len(targets))
}

Expand Down
5 changes: 3 additions & 2 deletions scan_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -3,13 +3,14 @@ package meddler
import (
"database/sql"
"fmt"
_ "github.com/mattn/go-sqlite3"
"reflect"
"sort"
"strings"
"sync"
"testing"
"time"

_ "github.com/mattn/go-sqlite3"
)

var once sync.Once
Expand Down Expand Up @@ -162,7 +163,7 @@ func personEqual(t *testing.T, elt *Person, ref *Person) {
t.Errorf("Person %s Email is %v", ref.Name, elt.Email)
}
if elt.Ephemeral != ref.Ephemeral {
t.Errorf("Person %s Ephemeral is %v", ref.Ephemeral, elt.Ephemeral)
t.Errorf("Person %d Ephemeral is %d", ref.Ephemeral, elt.Ephemeral)
}
if elt.Age != ref.Age {
t.Errorf("Person %s Age is %v", ref.Name, elt.Age)
Expand Down

0 comments on commit 6a044b2

Please sign in to comment.