Skip to content

Commit 7b4c45d

Browse files
author
James Cor
committed
again
1 parent d1d64b6 commit 7b4c45d

File tree

1 file changed

+4
-1
lines changed

1 file changed

+4
-1
lines changed

enginetest/enginetests.go

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1074,6 +1074,7 @@ func TestUserPrivileges(t *testing.T, h Harness) {
10741074
defer engine.Close()
10751075

10761076
engine.Analyzer.Catalog.MySQLDb.AddRootAccount()
1077+
engine.Analyzer.Catalog.MySQLDb.CanPersist = true
10771078
rootCtx := harness.NewContextWithClient(sql.Client{
10781079
User: "root",
10791080
Address: "localhost",
@@ -1172,9 +1173,9 @@ func TestUserAuthentication(t *testing.T, h Harness) {
11721173
}
11731174

11741175
engine := mustNewEngine(t, harness)
1175-
engine.Analyzer.Catalog.MySQLDb.CanPersist = true
11761176
defer engine.Close()
11771177
engine.Analyzer.Catalog.MySQLDb.AddRootAccount()
1178+
engine.Analyzer.Catalog.MySQLDb.CanPersist = true
11781179
if script.SetUpFunc != nil {
11791180
script.SetUpFunc(ctx, t, engine)
11801181
}
@@ -5440,6 +5441,8 @@ func TestPrivilegePersistence(t *testing.T, h Harness) {
54405441
},
54415442
)
54425443

5444+
engine.Analyzer.Catalog.MySQLDb.CanPersist = true
5445+
54435446
RunQueryWithContext(t, engine, harness, ctx, "CREATE USER tester@localhost")
54445447
// If the user exists in []*mysql_db.User, then it must be NOT nil.
54455448
require.NotNil(t, findUser("tester", "localhost", users))

0 commit comments

Comments
 (0)