-
Hello,
I'm working on a package that wraps an sql.Driver and adds functionality.
To test it, I'm trying to use go-sqlmock.
I'm running into the issue that if I wrap the go-sqlmock Driver, all ope…
-
I've found a case where calling `db.Close()` in different ways only sometimes satisfies `mock.ExpectClose()`. For example, if I call `sqlmock.New()` and then call `defer db.Close()` on the DB handle t…
-
下記ができていればクローズ
- https://github.com/DATA-DOG/go-sqlmockを利用してUser repositoryのテストを実施する
- sqlmock利用のドキュメントをwikiに記載する
-
This is the Error I'm getting
**`all expectations were already fulfilled, call to database transaction Begin was not expected`**
I have a code in my go lang
```
var userRoles models.UserRole
us…
-
is it possible to create a mysql database in memory use go-sqlmock?
just like https://github.com/alicebob/miniredis which creates a redis server in your own computer's memory with golang.
if so, we…
-
What version of Go are you using (go version)?
go version go1.14 darwin/amd64
github.com/DATA-DOG/go-sqlmock v1.4.1
github.com/jinzhu/gorm v1.9.12
Which database and its version are you usin…
-
Hello.
Now, only used vet and fmt as linters.
It's not a problem but we can use more linters by [golangci-lint](https://github.com/golangci/golangci-lint).
It might be better to introduce more lint…
-
**Is your feature request related to a problem? Please describe.**
We use `stdlib` pgx in our project. For unit tests we use [sqlmock](https://github.com/DATA-DOG/go-sqlmock) for unit tests. We wan…
-
It is possible to filter a row within the mocked rows? When i try to perform a query the result is always empty.
```go
type RepositoryTestSuit struct {
suite.Suite
repository Repository
data…
-
在 Go 单元测试这个系列的第二部分 [数据库的Mock测试](https://mp.weixin.qq.com/s?__biz=MzUzNTY5MzU2MA==&mid=2247493173&idx=1&sn=ef47fc8591a1976e0e254ed76cb1e144&chksm=fa8337a2cdf4beb45a1b55c0e231fa3f340afc4d37f590b237faedc…