0

我正在尝试使用 Tosca 自动化 Salesforce 实例,并且我使用“自动化数据驱动测试用例”,这只是使用 Tosca 工具记录测试用例选项,当我尝试通过“在剪贴簿中运行”执行测试用例成功记录后选项,我看到错误为

No suitable value found for command 'XL'

奇怪,因为我看到值已填充到 Excel 的 Tosca 测试引擎中,这是由于在错误信息 此处记录而生成的

这是来自 Tosca 的详细错误日志

            Tricentis.Automation.AutomationInstructions.TestActions.InvalidActionException: No suitable value found for command 'XL' ---> System.InvalidOperationException: No suitable value found for command 'XL'
            at Tricentis.Automation.AutomationInstructions.Dynamic.Values.ValueFactory.CreateValues(IParsed parsed, DataType dataType)
            at System.Linq.Enumerable.<SelectManyIterator>d__17`2.MoveNext()
            at System.Linq.Buffer`1..ctor(IEnumerable`1 source)
            at System.Linq.Enumerable.ToArray[TSource](IEnumerable`1 source)
            at Tricentis.Automation.AutomationInstructions.Dynamic.Values.ValueFactory.CreateValue(IEnumerable`1 parsedItems, DataType dataType)
            at Tricentis.Automation.AutomationInstructions.Dynamic.ExpressionParser.ParseExpression(String expression, IEnumerable`1 tokenDefinitions, DataType dataType)
            at Tricentis.Automation.AutomationInstructions.Dynamic.ExpressionParser.GetAsValues[T](String expression, TokenDefinitionSet tokenDefinitionSet, DataType dataType)
            at Tricentis.Automation.AutomationInstructions.TestActions.AutomationObjectTestAction.get_Values()
            at Tricentis.Automation.AutomationInstructions.TestActions.AutomationObjectTextBoxTestAction.get_Values()
            at Tricentis.Automation.AutomationInstructions.TestActions.AutomationObjectTestAction.CreateSubTestActions()
            at Tricentis.Automation.AutomationInstructions.TestActions.TestAction.get_InnerActions()
            --- End of inner exception stack trace ---
            at Tricentis.Automation.AutomationInstructions.TestActions.TestAction.get_InnerActions()
            at Tricentis.Automation.AutomationInstructions.TestActions.TestAction.get_Actions()
            at Tricentis.Automation.AutomationInstructions.TestActions.TestAction.<>c.<get_ExecutableChildren>b__32_1(ITestAction testAction)
            at System.Linq.Enumerable.WhereListIterator`1.MoveNext()
            at System.Collections.Generic.List`1..ctor(IEnumerable`1 collection)
            at System.Linq.Enumerable.ToList[TSource](IEnumerable`1 source)
            at Tricentis.Automation.AutomationInstructions.TestActions.TestAction.get_ExecutableChildren()
            at Tricentis.Automation.AutomationInstructions.TestActions.TestAction.get_ConstrainingChildren()
            at Tricentis.Automation.AutomationInstructions.TestActions.AutomationObjectSearchQuery.get_TestActionConstraints()
            at Tricentis.Automation.Engines.Representations.Controllers.RepresentationController.get_ConstrainingChildTestActions()
            at Tricentis.Automation.Engines.Representations.Controllers.RepresentationController.ConstrainBySubItems(IEnumerable`1 representations)
            at Tricentis.Automation.Engines.Representations.Controllers.RepresentationController.ConstrainInternal(IEnumerable`1 representations, IModuleAttributeXParameters parameters)
            at Tricentis.Automation.Engines.Representations.Controllers.RepresentationController.Constrain(IEnumerable`1 representations)
            at Tricentis.Automation.Engines.Representations.Controllers.RepresentationController.SearchRepresentations(IAdapterController adapterController)
            at Tricentis.Automation.Engines.Representations.Controllers.RootRepresentationController.SearchRepresentation()
            at Tricentis.Automation.Engines.Representations.Controllers.RepresentationController.Search()
            at ᜁ.ᜀ(IRepresentationController A_0)
            at ᜁ.ᜁ(IRepresentationController A_0, IRepresentation& A_1)
            at ᜂ.ᜀ(IRepresentationController A_0, IRepresentation& A_1)
            at ᜁ.ᜀ()
4

1 回答 1

2

即使我得到了同样的错误信息。但现在解决了。我尝试如下:将测试用例转换为模板,并通过在各个位置拖放将测试表属性添加到模板。如果此时您尝试运行测试步骤,您将收到此错误消息“找不到命令 'XL' 的合适值”,这可以通过菜单中的“创建模板实例”或从图标中的实例化图标来避免工具栏,然后运行 ​​Scratch Book 中的实例化项目。它应该可以在没有任何错误消息的情况下工作。我使用了多个用户案例,并且所有这些都有效。注意:其他观察:确保不要使用右键单击和交叉标记删除单元格中的值。只需进入牢房,然后删除。

于 2020-10-28T00:56:46.220 回答