-
https://blog.marvel6.cn/2020/01/test-and-mock-db-by-xorm-with-the-help-of-convey-and-sqlmock/
一直以来,团队同学(也包括我自己)对单元测试不够重视,代码覆盖率几乎等于 0, 最直接的后果是代码 bug 率较高,重构困难。从 PHP 转为 Golang 开发已有一年多,
-
I have a query that I run that has a few `sql.Out` parameters. Using go-sqlmock, it doesn't appear to be possible to have values injected into the `Dest` field of a `sql.Out` parameter when the query …
-
I needed to upgrade oto for MAC, and then noticed all needed to be.
The tests all pass with a go.mod of:
```
module github.com/faiface/beep
go 1.14
require (
github.com/gdamore/tcell v1…
-
Is there a mocking library that works well with XORM. I've been trying to get `gopkg.in/DATA-DOG/go-sqlmock.v1` to work but it's such a hassle to even get it running. When I try to mock complicated qu…
-
I have an application that I am trying to test where I am using a pgx connection. I would like to be able to inject a mock connection into my code where I can then expect/return expectations for that …
-
It seems, there is not an adapter written specifically for testing. It would be nice to have an adapter which utilizes memory instead of disk.
-
My code uses pg.Array to read a `text[]` field. Can I use this package to test this code? ... if so, how?
Thanks!
-
In glide 0.12.3 and 0.12.2 (downloaded binaries from GIT) on an amd64 machine, Glide stops fetching after the first 16 items.
Any help/tips/suggestions are greatly appreciated.
Example output of…
-
When using`WillReturnCloseError` on an `ExpectedPrepare` but not using transactions,`Close()` is not returning the error given to `WillReturnCloseError`
Expected behaviour: `stmt.Close() == wantErr…
-
I'm thinking we try to test this against the major SQL DBs, such as Oracle, MySQL, Postgress (probably not needed since they have a pretty snazzy client), MsSQL/TSQL/SQLServer, and whatever else that …