The highest tagged major version is
v6.
package
Version:
v4.1.0
Opens a new window with list of versions in this module.
Published: Feb 22, 2022
License: MIT
Opens a new window with license information.
Imports: 10
Opens a new window with list of imports.
Imported by: 0
Opens a new window with list of known importers.
Documentation
¶
Package test 提供了整个包的基本测试数据
type Driver struct {
*assert.Assertion
DB *orm.DB
DriverName string
DBName string
}
Driver 单个测试用例
Suite 测试用例管理
NewSuite 初始化测试内容
dialect 指定了当前需要测试的驱动,如果未指定表示需要测全部,否则只测试指定内容。
同时 dialect 还受到 flagsets.Flags 变量的影响,如果未在其中指定的,也不会执行测试。
Close 销毁测试用例并关闭数据库
如果是 sqlite3,还会删除数据库文件。
ForEach 为每个数据库测试用例调用 f 进行测试
dialects 为需要测试的驱动,如果为空表示测试全部
Source Files
¶
Click to show internal directories.
Click to hide internal directories.