【问题标题】:SoapUI Groovy GotoTestStep in other Testcase其他测试用例中的 SoapUI Groovy GotoTestStep
【发布时间】:2017-12-14 11:28:10
【问题描述】:

我在 SoapUI 中有一个带有 2 个测试用例的测试套件。 例如带有测试用例 1 和测试用例 2 的 TestSuite1

TestCase1 有一个 Groovy-TestStep1。 Groovy-TestStep1 应该转到 TestCase 2 中的 TestStep4 (Groovy-TestStep1应该去TestStep4而不是运行TestStep4)

有可能吗?

测试用例1 TestStep1 (groovy)

测试用例2 testStep1 (http 请求) testStep2 调用 TestCase1 TestStep3(http请求) TestStep4 ((http-request) TestStep5 (http-Request)

非常感谢您的回答

迈克尔

【问题讨论】:

  • 你有什么用?你想让我做什么 ? Go there and don't run - 解释一下?

标签: groovy soapui


【解决方案1】:

可以调用其他测试套件中的测试步骤。您可以尝试以下方法:

def otherTestSuite = testRunner.testCase.testSuite.project.getTestSuiteByName("OtherTestSuite")
def otherTestStep = otherTestSuite.getTestCaseByName("otherTestCase").getTestStepByName("otherTestStep")
otherTestStep.run (testRunner, context) 

【讨论】:

    猜你喜欢
    • 2018-02-28
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 2014-12-26
    • 1970-01-01
    • 1970-01-01
    • 2018-05-24
    相关资源
    最近更新 更多