tests/pessimistictest: fix DATA RACE for tests (#34505)
tests/pessimistictest: fix DATA RACE for tests (#34505)

close pingcap/tidb#34504
kyle-wang/tidb,pingcap/tidb,ngaut/tidb,kyle-wang/tidb,c4pt0r/tidb,c4pt0r/tidb,pingcap/tidb,ngaut/tidb,ngaut/tidb,c4pt0r/tidb,c4pt0r/tidb,ngaut/tidb,kyle-wang/tidb,ngaut/tidb,pingcap/tidb,kyle-wang/tidb,ngaut/tidb,c4pt0r/tidb,c4pt0r/tidb,kyle-wang/tidb,pingcap/tidb,pingcap/tidb,pingcap/tidb,kyle-wang/tidb