From 95ae0c83d2aa58d86b4039e3f7f16ee93afb8f00 Mon Sep 17 00:00:00 2001
From: 云 <2163098428@qq.com>
Date: 星期五, 23 十月 2026 17:01:00 +0800
Subject: [PATCH] feat(ai): 完善模型管理和智能体导入功能

---
 yudao-module-mdm/src/test/java/cn/iocoder/yudao/module/mdm/service/agent/MdmAgentImportCommandServiceTest.java |   10 +++++-----
 1 files changed, 5 insertions(+), 5 deletions(-)

diff --git a/yudao-module-mdm/src/test/java/cn/iocoder/yudao/module/mdm/service/agent/MdmAgentImportCommandServiceTest.java b/yudao-module-mdm/src/test/java/cn/iocoder/yudao/module/mdm/service/agent/MdmAgentImportCommandServiceTest.java
index d112132..fc0d17b 100644
--- a/yudao-module-mdm/src/test/java/cn/iocoder/yudao/module/mdm/service/agent/MdmAgentImportCommandServiceTest.java
+++ b/yudao-module-mdm/src/test/java/cn/iocoder/yudao/module/mdm/service/agent/MdmAgentImportCommandServiceTest.java
@@ -49,7 +49,7 @@
     @Mock private PlatformTransactionManager transactionManager;
     @InjectMocks private MdmAgentImportCommandService service;
 
-    private final AgentPrincipal principal = new AgentPrincipal(7L, 0L, "live");
+    private final AgentPrincipal principal = new AgentPrincipal(7L, "live");
 
     @BeforeEach
     void setUp() {
@@ -81,7 +81,7 @@
         AtomicReference<MdmAgentImportCommandDO> inserted = captureInsertedCommand();
 
         MdmAgentImportReceiptRespVO first = service.commit(request("鐗╂枡A"), principal);
-        when(commandMapper.selectByCommandId(0L, 7L, "cmd-1")).thenReturn(inserted.get());
+        when(commandMapper.selectByCommandId(7L, "cmd-1")).thenReturn(inserted.get());
         MdmAgentImportReceiptRespVO second = service.commit(request("鐗╂枡A"), principal);
 
         assertEquals("SUCCEEDED", first.getStatus());
@@ -95,8 +95,8 @@
         when(preflightService.preflight(any(), any())).thenReturn(preflight(PREFLIGHT_HASH));
         AtomicReference<MdmAgentImportCommandDO> inserted = captureInsertedCommand();
         service.commit(request("鐗╂枡A"), principal);
-        when(commandMapper.selectByCommandId(0L, 7L, "cmd-1")).thenReturn(inserted.get());
-        when(commandMapper.selectByIdempotencyKey(0L, 7L, "idem-1")).thenReturn(null);
+        when(commandMapper.selectByCommandId(7L, "cmd-1")).thenReturn(inserted.get());
+        when(commandMapper.selectByIdempotencyKey(7L, "idem-1")).thenReturn(null);
 
         AgentBridgeException ex = assertThrows(AgentBridgeException.class,
                 () -> service.commit(request("鐗╂枡B"), principal));
@@ -115,7 +115,7 @@
 
     @Test
     void missingCommandReturnsNotFound() {
-        when(commandMapper.selectByCommandId(0L, 7L, "cmd-x")).thenReturn(null);
+        when(commandMapper.selectByCommandId(7L, "cmd-x")).thenReturn(null);
 
         AgentBridgeException ex = assertThrows(AgentBridgeException.class,
                 () -> service.getCommand("cmd-x", principal));

--
Gitblit v1.9.3