From 2d573f019199bcca0659ca761e93074ddd7ee61b Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E4=B9=BE=E9=98=B3=E7=86=A0?= Date: Sat, 16 Aug 2025 07:33:26 +0000 Subject: [PATCH] =?UTF-8?q?update=20test/unittest/param/trigger=5Funittest?= =?UTF-8?q?.cpp.=20Signed-off-by:=20=E4=B9=BE=E9=98=B3=E7=86=A0=20?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: 乾阳熠 --- test/unittest/param/trigger_unittest.cpp | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/test/unittest/param/trigger_unittest.cpp b/test/unittest/param/trigger_unittest.cpp index cea221c89..7eaae1383 100644 --- a/test/unittest/param/trigger_unittest.cpp +++ b/test/unittest/param/trigger_unittest.cpp @@ -208,6 +208,7 @@ public: CheckTrigger(GetTriggerWorkSpace(), TRIGGER_PARAM, buffer, strlen(buffer), TestTriggerExecute); EXPECT_EQ(0, g_matchTrigger); + SystemWriteParam(param, value); g_matchTrigger = 0; ret = sprintf_s(buffer, sizeof(buffer), "%s=%s", param, value); EXPECT_GE(ret, 0); @@ -230,6 +231,7 @@ public: { const char *triggerName = "param:test_param.222"; const char *param = "test_param.aaa.222.2222"; + SystemWriteParam(param, "2"); char buffer[triggerBuffer]; int ret = sprintf_s(buffer, sizeof(buffer), "%s=*", param); EXPECT_GE(ret, 0); @@ -256,6 +258,8 @@ public: const char *triggerName = "param:test_param.333"; const char *param1 = "test_param.aaa.333.2222=1"; const char *param2 = "test_param.aaa.333.3333=2"; + SystemWriteParam("test_param.aaa.333.2222", "1"); + SystemWriteParam("test_param.aaa.333.3333", "2"); char buffer[triggerBuffer]; int ret = sprintf_s(buffer, sizeof(buffer), "%s || %s", param1, param2); EXPECT_GE(ret, 0); -- Gitee