mirror of
https://github.com/featurebasedb/featurebase.git
synced 2026-09-07 00:55:55 +00:00
Merge pull request #936 from raskle/fix-test-string-format
Fix test string format
This commit is contained in:
commit
bbc82d166d
3 changed files with 10 additions and 5 deletions
|
|
@ -90,7 +90,7 @@ func TestClient_MultiNode(t *testing.T) {
|
|||
}
|
||||
}
|
||||
if !ownsNum {
|
||||
t.Fatalf("Trying to use slice %d on host %s, but it doesn't own that slice. It owns %s", num, s[i].Host(), owns)
|
||||
t.Fatalf("Trying to use slice %d on host %s, but it doesn't own that slice. It owns %v", num, s[i].Host(), owns)
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -305,7 +305,7 @@ func TestExecutor_Execute_SetFieldValue(t *testing.T) {
|
|||
} else if !exists {
|
||||
t.Fatal("expected value to exist")
|
||||
} else if value != 25 {
|
||||
t.Fatal("unexpected value: %v", value)
|
||||
t.Fatalf("unexpected value: %v", value)
|
||||
}
|
||||
|
||||
if value, exists, err := f.FieldValue(10, "field1"); err != nil {
|
||||
|
|
@ -313,7 +313,7 @@ func TestExecutor_Execute_SetFieldValue(t *testing.T) {
|
|||
} else if !exists {
|
||||
t.Fatal("expected value to exist")
|
||||
} else if value != 2 {
|
||||
t.Fatal("unexpected value: %v", value)
|
||||
t.Fatalf("unexpected value: %v", value)
|
||||
}
|
||||
|
||||
if value, exists, err := f.FieldValue(100, "field0"); err != nil {
|
||||
|
|
@ -321,7 +321,7 @@ func TestExecutor_Execute_SetFieldValue(t *testing.T) {
|
|||
} else if !exists {
|
||||
t.Fatal("expected value to exist")
|
||||
} else if value != 10 {
|
||||
t.Fatal("unexpected value: %v", value)
|
||||
t.Fatalf("unexpected value: %v", value)
|
||||
}
|
||||
})
|
||||
|
||||
|
|
@ -781,7 +781,7 @@ func TestExecutor_Execute_FieldRange(t *testing.T) {
|
|||
t.Fatal(err)
|
||||
} else if !reflect.DeepEqual([]uint64{0}, result[0].(*pilosa.Bitmap).Bits()) {
|
||||
//t.Fatalf("unexpected result: %s", spew.Sdump(result))
|
||||
t.Fatalf("unexpected result: %s", result[0].(*pilosa.Bitmap).Bits())
|
||||
t.Fatalf("unexpected result: %v", result[0].(*pilosa.Bitmap).Bits())
|
||||
}
|
||||
})
|
||||
|
||||
|
|
|
|||
5
uri.go
5
uri.go
|
|
@ -134,6 +134,11 @@ func (u *URI) Normalize() string {
|
|||
return fmt.Sprintf("%s://%s:%d", scheme, u.host, u.port)
|
||||
}
|
||||
|
||||
// String returns the address as a string.
|
||||
func (u URI) String() string {
|
||||
return fmt.Sprintf("%s://%s:%d", u.scheme, u.host, u.port)
|
||||
}
|
||||
|
||||
// Equals returns true if the checked URI is equivalent to this URI.
|
||||
func (u URI) Equals(other *URI) bool {
|
||||
if other == nil {
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue