Skip to content

Commit

Permalink
fix CI
Browse files Browse the repository at this point in the history
Signed-off-by: hehechen <chentongli@pingcap.com>
  • Loading branch information
hehechen committed Dec 20, 2022
1 parent 3c1d1fa commit 69a89e5
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 12 deletions.
6 changes: 3 additions & 3 deletions executor/tiflashtest/tiflash_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -1037,7 +1037,7 @@ func TestTiFlashPartitionTableBroadcastJoin(t *testing.T) {
}
}

func TestForbidTiflashDuringStaleRead(t *testing.T) {
func TestTiflashSupportStaleRead(t *testing.T) {
store := testkit.CreateMockStore(t, withMockTiFlash(2))
tk := testkit.NewTestKit(t, store)
tk.MustExec("use test")
Expand Down Expand Up @@ -1069,8 +1069,8 @@ func TestForbidTiflashDuringStaleRead(t *testing.T) {
fmt.Fprintf(resBuff, "%s\n", row)
}
res = resBuff.String()
require.NotContains(t, res, "tiflash")
require.Contains(t, res, "tikv")
require.Contains(t, res, "tiflash")
require.NotContains(t, res, "tikv")
}

func TestForbidTiFlashIfExtraPhysTableIDIsNeeded(t *testing.T) {
Expand Down
12 changes: 3 additions & 9 deletions sessionctx/variable/session_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,6 @@ import (
"github.com/pingcap/tidb/parser"
"github.com/pingcap/tidb/parser/auth"
"github.com/pingcap/tidb/parser/mysql"
"github.com/pingcap/tidb/planner/core"
plannercore "github.com/pingcap/tidb/planner/core"
"github.com/pingcap/tidb/sessionctx/stmtctx"
"github.com/pingcap/tidb/sessionctx/variable"
Expand Down Expand Up @@ -130,14 +129,9 @@ func TestSession(t *testing.T) {
}

func TestAllocMPPID(t *testing.T) {
ctx := mock.NewContext()

seVar := ctx.GetSessionVars()
require.NotNil(t, seVar)

require.Equal(t, int64(1), core.AllocMPPTaskID())
require.Equal(t, int64(2), core.AllocMPPTaskID())
require.Equal(t, int64(3), core.AllocMPPTaskID())
require.Equal(t, int64(2), plannercore.AllocMPPTaskID())
require.Equal(t, int64(3), plannercore.AllocMPPTaskID())
require.Equal(t, int64(4), plannercore.AllocMPPTaskID())
}

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

0 comments on commit 69a89e5

Please sign in to comment.