1,优化撤销功能,对调试结果信息不记录撤销

2,优化F10测试流程,连续调试时不清空测试记录
This commit is contained in:
2025-06-12 21:59:43 +08:00
parent 4581aa6492
commit 16aa21550d
27 changed files with 507 additions and 332 deletions

View File

@@ -22,13 +22,14 @@ Namespace UTSModule.Test.Command.SystemCommand
Public Overrides Function Execute() As TestCommandReturn
Dim tester As UtsTester = UtsTester.CreateTester()
Dim rowNode As RowNode = tester.GetModule(_moduleName)
rowNode.IsRetry = IsRetry
If rowNode Is Nothing Then
CommandReturn.ExecuteResult = False
CommandReturn.RecordValue = String.Empty
CommandReturn.ExecuteResultTipString = $"未查询到[{_moduleName}]模块存在"
Else
rowNode.IsRetry = IsRetry
Dim moduleResult As TestCommandReturn = tester.ExecutePlan(rowNode, _localVariable)
CommandReturn.ExecuteResult = moduleResult.ExecuteResult

View File

@@ -52,6 +52,7 @@ Namespace UTSModule.Test.Controls
Public Overloads Shared Function ShowDialog(tip As String, Optional title As String = "", Optional text As String = "", Optional isPwd As Boolean = False) As String
Using box As New UtsInputBox
box.TopLevel = True
box.TipText = tip
box.Title = title
box.DefaultText = text

View File

@@ -16,6 +16,7 @@ Namespace UTSModule.Test.Controls
Public Overloads Shared Function ShowDialog(text As String, Optional type As UtsMsgBoxTypeEnum = UtsMsgBoxTypeEnum.OkOnly, Optional title As String = "") As System.Windows.Forms.DialogResult
Using msg As New UtsMsgBox
msg.TopLevel = True
msg.MsgText = text
msg.MsgType = type
msg.MsgTitle = title

View File

@@ -226,6 +226,10 @@ Namespace UTSModule.Test
Next
Dim moduleNode As RowNode = GetModule(moduleName)
If moduleNode Is Nothing Then
MsgBox($"行号:{node.RowListIndex} 未找到可调用模块:{moduleName}")
Continue For
End If
SearchRecordName(moduleNode.RowNodes, True, variable)
End If
Next

View File

@@ -546,6 +546,9 @@ Namespace UTSModule.Test
If _exitTest Then Return GetExitTestReturn()
If node.Action = False Then Return GetNotActionNodeResult()
If node.RowType = RowNode.RowTypeEnum.Flow Then
If String.IsNullOrEmpty(node.CommandType) OrElse String.IsNullOrEmpty(node.Command) Then Return GetNotActionNodeResult()
End If
If TestStatus = TestStatusEnum.Testing Then _testNode = node
@@ -1025,7 +1028,7 @@ Namespace UTSModule.Test
''' 调试测试当前节点及其子节点
''' </summary>
''' <param name="obj">节点对象</param>
Public Sub TestNode(obj As Object)
Public Function TestNode(obj As Object) As TestCommandReturn
Dim node As RowNode = CType(obj, RowNode)
DebugMode = True
@@ -1071,8 +1074,8 @@ Namespace UTSModule.Test
RaiseEvent TestEnd(Me, New TestEndEventArgs(_testResult))
End Sub
Return result
End Function
''' <summary>
''' 从当前节点调试测试,直到测试完当前顶级模块