go-sqlmock
go-sqlmock copied to clipboard
Sql mock driver for golang to test database interactions
### Issue Hey there, it looks like your License isn't being interpreted by GitHub correctly, which means that it's not in the proper format. This is an example of using...
I do not have much spare time for this library and willing to transfer the repository ownership to person or an organization motivated to maintain it. Open up a conversation...
Hi, having trouble with using go routines. `sqlmock version 1.5.0` below is the code when functions run serial no error occurs but panics when used with goroutines. 🖊️ update: second...
I'm trying to unit test a scenario where I get a duplicate key error but am not able to do the same. service.go ``` func (s *service) addNewUser(newUser *models.User) error...
Hi, guys, i wrote one pice of code as below, but i couldn't use WithArgs like this: mock.ExpectQuery(query2).WithArgs(122).WillReturnRows(rs2),so i have to use it like this: **query2:= "SELECT (.+) as count...
Hello, I am having a problem when I working with gorm v2. I have tried every solution and I could find but none worked. gorm version: 1.22.4 sqlmock version: v1.5.0...
### Proposal The last Go version Travis supports is v1.17! This can be updated to v1.18
It's easier to develop
**what happened:** when I want to test ``` _, err := o.QueryTable(Quota{}).Filter("project", project).Update(orm.Params{ "used": used, "update_at": time.Now().UTC(), }) ``` expected sql I tested with `UPDATE "quota" SET "used" = $1,...