Skip to content

Commit

Permalink
fix ci
Browse files Browse the repository at this point in the history
  • Loading branch information
tiancaiamao authored and ti-chi-bot committed Mar 15, 2023
1 parent a6002cd commit 451e9ce
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions executor/stale_txn_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -508,15 +508,15 @@ func TestStalenessTransactionSchemaVer(t *testing.T) {

// get the specific old schema
tk.MustExec(fmt.Sprintf(`START TRANSACTION READ ONLY AS OF TIMESTAMP '%s'`, time1.Format("2006-1-2 15:04:05.000")))
require.Equal(t, schemaVer1, tk.Session().GetInfoSchema().SchemaMetaVersion())
require.Equal(t, schemaVer1, sessiontxn.GetTxnManager(tk.Session()).GetTxnInfoSchema().SchemaMetaVersion())

// schema changed back to the newest
tk.MustExec("commit")
require.Equal(t, schemaVer2, tk.Session().GetInfoSchema().SchemaMetaVersion())
require.Equal(t, schemaVer2, sessiontxn.GetTxnManager(tk.Session()).GetTxnInfoSchema().SchemaMetaVersion())

// select does not affect the infoschema
tk.MustExec(fmt.Sprintf(`SELECT * from t AS OF TIMESTAMP '%s'`, time1.Format("2006-1-2 15:04:05.000")))
require.Equal(t, schemaVer2, tk.Session().GetInfoSchema().SchemaMetaVersion())
require.Equal(t, schemaVer2, sessiontxn.GetTxnManager(tk.Session()).GetTxnInfoSchema().SchemaMetaVersion())
}

func TestSetTransactionReadOnlyAsOf(t *testing.T) {
Expand Down

0 comments on commit 451e9ce

Please sign in to comment.