mirror of
https://gitee.com/johng/gf
synced 2026-07-04 13:02:36 +08:00
fix(contrib/drivers/mysql): use unreachable port for nodeInvalid test config (#4726)
## Summary - Change nodeInvalid port from 3307 to 3316 (default 3306 + 10) so the connection is guaranteed to fail as intended - Port 3307 may collide with a running MariaDB instance in CI, causing nodeInvalid to accidentally connect to a live database ref #4689
This commit is contained in:
@ -58,7 +58,7 @@ func init() {
|
||||
nodePrefix.Prefix = TableNamePrefix1
|
||||
|
||||
nodeInvalid := gdb.ConfigNode{
|
||||
Link: fmt.Sprintf("mysql:root:%s@tcp(127.0.0.1:3307)/?loc=Local&parseTime=true", TestDbPass),
|
||||
Link: fmt.Sprintf("mysql:root:%s@tcp(127.0.0.1:3316)/?loc=Local&parseTime=true", TestDbPass),
|
||||
TranTimeout: time.Second * 3,
|
||||
}
|
||||
gdb.AddConfigNode("test", nodeDefault)
|
||||
|
||||
Reference in New Issue
Block a user