Skip to content

Fix duplicate key test case #111

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 2 commits into from
Nov 26, 2021
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 4 additions & 4 deletions example_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -119,7 +119,7 @@ func Example() {
fmt.Println("Insert Data", resp.Data)

// insert new tuple { 11, 1 }
resp, err = client.Insert("test", &Tuple{Id: 10, Msg: "test", Name: "one"})
resp, err = client.Insert("test", &Tuple{Id: 11, Msg: "test", Name: "one"})
fmt.Println("Insert Error", err)
fmt.Println("Insert Code", resp.Code)
fmt.Println("Insert Data", resp.Data)
Expand Down Expand Up @@ -194,9 +194,9 @@ func Example() {
// Insert Error <nil>
// Insert Code 0
// Insert Data [[10 test one]]
// Insert Error Duplicate key exists in unique index 'primary' in space 'test' (0x3)
// Insert Code 3
// Insert Data []
// Insert Error <nil>
// Insert Code 0
// Insert Data [[11 test one]]
// Delete Error <nil>
// Delete Code 0
// Delete Data [[10 test one]]
Expand Down
2 changes: 1 addition & 1 deletion tarantool_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -439,7 +439,7 @@ func TestClient(t *testing.T) {
t.Errorf("Expected ErrTupleFound but got: %v", err)
}
if len(resp.Data) != 0 {
t.Errorf("Response Body len != 1")
t.Errorf("Response Body len != 0")
}

// Delete
Expand Down