*: fix ineffective failpoint enable in TestMPPExecution (#46429)

This commit is contained in:
David
2023-08-25 21:57:35 +08:00
committed by GitHub
parent e69783571b
commit 89ba8fd565

View File

@ -272,10 +272,10 @@ func TestMppExecution(t *testing.T) {
require.Equal(t, int64(1), taskID)
tk.MustExec("commit")
failpoint.Enable("github.com/pingcap/tidb/executor/checkTotalMPPTasks", `return(3)`)
require.NoError(t, failpoint.Enable("github.com/pingcap/tidb/executor/internal/mpp/checkTotalMPPTasks", `return(3)`))
// all the data is related to one store, so there are three tasks.
tk.MustQuery("select avg(t.a) from t join t t1 on t.a = t1.a").Check(testkit.Rows("2.0000"))
failpoint.Disable("github.com/pingcap/tidb/executor/internal/mpp/checkTotalMPPTasks")
require.NoError(t, failpoint.Disable("github.com/pingcap/tidb/executor/internal/mpp/checkTotalMPPTasks"))
tk.MustExec("drop table if exists t")
tk.MustExec("create table t (c1 decimal(8, 5) not null, c2 decimal(9, 5), c3 decimal(9, 4) , c4 decimal(8, 4) not null)")