From 443c38da0e670b8ba2cdc223814c65228903f1ce Mon Sep 17 00:00:00 2001 From: Weizhen Wang Date: Wed, 18 Oct 2023 11:42:29 +0800 Subject: [PATCH] *: simple code (#47737) --- pkg/ddl/placement_policy_test.go | 2 +- pkg/executor/test/admintest/admin_test.go | 2 +- pkg/planner/core/plan_test.go | 4 ++-- .../handle/handletest/lockstats/lock_partition_stats_test.go | 2 +- 4 files changed, 5 insertions(+), 5 deletions(-) diff --git a/pkg/ddl/placement_policy_test.go b/pkg/ddl/placement_policy_test.go index efa873e0b69de..c3a95cce9bc1f 100644 --- a/pkg/ddl/placement_policy_test.go +++ b/pkg/ddl/placement_policy_test.go @@ -844,7 +844,7 @@ func TestCreateSchemaWithInfoPlacement(t *testing.T) { } func TestAlterRangePlacementPolicy(t *testing.T) { - store, _ := testkit.CreateMockStoreAndDomain(t) + store := testkit.CreateMockStore(t) tk := testkit.NewTestKit(t, store) tk.MustExec("create placement policy fiveReplicas followers=4") tk.MustExec("alter range global placement policy fiveReplicas") diff --git a/pkg/executor/test/admintest/admin_test.go b/pkg/executor/test/admintest/admin_test.go index 3b4b599c233a0..63c7bb4372965 100644 --- a/pkg/executor/test/admintest/admin_test.go +++ b/pkg/executor/test/admintest/admin_test.go @@ -1772,7 +1772,7 @@ func TestAdminCheckTableErrorLocateForClusterIndex(t *testing.T) { } func TestAdminCheckTableErrorLocateBigTable(t *testing.T) { - store, _ := testkit.CreateMockStoreAndDomain(t) + store := testkit.CreateMockStore(t) tk := testkit.NewTestKit(t, store) tk.MustExec("use test") diff --git a/pkg/planner/core/plan_test.go b/pkg/planner/core/plan_test.go index 456eb943af9de..894fc966a9f35 100644 --- a/pkg/planner/core/plan_test.go +++ b/pkg/planner/core/plan_test.go @@ -756,7 +756,7 @@ func TestIssue40535(t *testing.T) { } func TestIssue47445(t *testing.T) { - store, _ := testkit.CreateMockStoreAndDomain(t) + store := testkit.CreateMockStore(t) tk := testkit.NewTestKit(t, store) tk.MustExec("use test;") tk.MustExec("CREATE TABLE golang1 ( `fcbpdt` CHAR (8) COLLATE utf8_general_ci NOT NULL, `fcbpsq` VARCHAR (20) COLLATE utf8_general_ci NOT NULL, `procst` char (4) COLLATE utf8_general_ci DEFAULT NULL,`cipstx` VARCHAR (105) COLLATE utf8_general_ci DEFAULT NULL, `cipsst` CHAR (4) COLLATE utf8_general_ci DEFAULT NULL, `dyngtg` VARCHAR(4) COLLATE utf8_general_ci DEFAULT NULL, `blncdt` VARCHAR (8) COLLATE utf8_general_ci DEFAULT NULL, PRIMARY KEY ( fcbpdt, fcbpsq ))") @@ -772,7 +772,7 @@ func TestIssue47445(t *testing.T) { } func TestExplainValuesStatement(t *testing.T) { - store, _ := testkit.CreateMockStoreAndDomain(t) + store := testkit.CreateMockStore(t) tk := testkit.NewTestKit(t, store) tk.MustMatchErrMsg("EXPLAIN FORMAT = TRADITIONAL ((VALUES ROW ()) ORDER BY 1)", ".*Unknown table ''.*") diff --git a/pkg/statistics/handle/handletest/lockstats/lock_partition_stats_test.go b/pkg/statistics/handle/handletest/lockstats/lock_partition_stats_test.go index fbc176e151eaa..9dea979559380 100644 --- a/pkg/statistics/handle/handletest/lockstats/lock_partition_stats_test.go +++ b/pkg/statistics/handle/handletest/lockstats/lock_partition_stats_test.go @@ -263,7 +263,7 @@ func TestUnlockTheUnlockedTableWouldGenerateWarning(t *testing.T) { } func TestSkipLockALotOfPartitions(t *testing.T) { - store, _ := testkit.CreateMockStoreAndDomain(t) + store := testkit.CreateMockStore(t) tk := testkit.NewTestKit(t, store) tk.MustExec("set @@tidb_analyze_version = 1") tk.MustExec("use test")