test-manager
2.2510
true
重要 :
新发布内容的本地化可能需要 1-2 周的时间才能完成。
UiPath logo, featuring letters U and I in white

Test Manager 用户指南

上次更新日期 2025年11月20日

自动化用户界面测试用例

在您的测试组合中加入自动化测试用例,以节省时间,自动化重复性任务。

选择自动化

要将自动化与测试用例相关联,请选择一个发布到 Orchestrator 的自动化。 建议在将自动化连接到测试用例的方法中直接在 Test Manager 中选择 Orchestrator 自动化。 如果未选择 Orchestrator 自动化,Test Manager 将回退到从 Studio 链接的自动化。

此外,如果测试用例仅链接 Studio 自动化,而未链接 Orchestrator 自动化,则 Test Manager 将尝试在 Orchestrator 中查找等效自动化以执行执行。
注意:如果 Test Manager 测试用例同时链接到 Studio 和 Orchestrator 中的自动化,则从 Orchestrator 选择的自动化优先于从 Studio 链接的自动化。

先决条件

注意:如果您直接在 Test Manager 中选择自动化,则在启用“允许执行旧版上下文”设置时(例如,未在项目或测试集级别选择执行文件夹时),不考虑所选自动化。 因此,如果您想直接在 Test Manager 中选择自动化,我们建议您禁用“允许旧版执行上下文”租户设置。
要从 Orchestrator 中选择自动化,请确保执行以下步骤:
  • 将 Studio 项目发布到租户包订阅源或另一个 Orchestrator 文件夹订阅源。
  • 为自己分配以下角色之一:
    • Automation User Orchestrator 文件夹角色
    • 具有管理权限的任何默认角色
    提示:首先,用户需要编辑测试用例的权限,以便直接在 Test Manager 中选择自动化。 在此上下文中,其他有用的权限包括拥有Automation User角色或任何具有管理权限的角色。

    有关默认租户角色的更多信息,请访问租户默认角色

步骤

要为测试用例选择自动化,请执行以下步骤:

  1. 转到项目的“测试用例”部分。
  2. 打开测试用例。
  3. 选择“自动化”选项卡。
  4. 选择“选择自动化”

    此操作将打开选择自动化右侧菜单。

    1. “包来源”下拉列表中,选择相应 Orchestrator 实例中的订阅源。

      此订阅源应包含您要链接到 Test Manager 测试用例的 Studio 测试用例。 默认选择为“租户包订阅源”

      只有拥有订阅源的文件夹才会出现在“包来源”下拉列表中。 在文件夹层次结构中,下拉列表中仅显示父文件夹,因为所有子文件夹共享相同的订阅源。

      注意:可用的包订阅源选项是您具有管理权限的选项。
    2. 选择包订阅源后,可以从该位置选择自动化。
      自动化名称显示在“测试用例名称”列下,已发布的包名称显示在“包”列下。
      注意: “测试用例名称”列显示在 Orchestrator 中发布自动化的文件夹,后跟自动化名称。 例如,如果您想选择从 Studio 发布到 Orchestrator 中Accounts文件夹的Create Checking Account测试用例,则此自动化的“测试用例名称”将为Accounts/Create Checking Account
  5. 选择“保存”以确认更改。

    从 Orchestrator 包订阅源中选择自动化后,您可以在“已分配的自动化”下的以下字段中检查自动化详细信息:

    • 包测试用例名称:在 Orchestrator 中发布自动化的文件夹,后跟自动化名称: FolderName/TestCaseName
    • 包名称:用于发布所选自动化的包名称。
    • 包来源:您发布包的 Orchestrator 订阅源。

更新自动化

要更新从 Orchestrator 订阅源中选择的自动化,请执行以下步骤:

  1. 转到项目的“测试用例”部分。
  2. 打开测试用例。
  3. 选择“自动化”选项卡。
  4. 选择“更新自动化”

    此操作将打开选择自动化右侧菜单。

    1. “包来源”下拉列表中,选择相应 Orchestrator 实例中的订阅源。

      此订阅源包含您要与 Test Manager 测试用例链接的 Studio 测试用例。

      默认选择为“租户包订阅源”

      注意:可用的包订阅源选项是您具有管理权限的选项。
    2. 选择包订阅源后,可以从该位置选择自动化。

      自动化名称显示在测试用例名称下,已发布的包名称显示在下。

  5. 选择“保存”以确认更改。

转移测试用例

如果您需要将测试用例转移到其他租户,则在您导出测试用例并将其重新导入到另一个租户时,系统会保留为每个测试用例选择的 Orchestrator 自动化。 有关导出测试用例和导入测试工件的更多信息,请访问导出测试用例导入项目

后续步骤

要执行包含使用从 Orchestrator 选择的自动化的测试用例的测试集,您可以指定特定的包和版本来运行测试用例。 这允许 Test Manager 仅使用选定的包和版本执行 Orchestrator 订阅源中多个包中链接到自动化的测试用例。

有关配置特定执行文件夹以及选择包和版本的更多信息,请访问为特定执行文件夹和机器人配置测试集

取消链接自动化

您可以从Test Manager中的任何测试用例中取消 Studio 和 Orchestrator 自动化的链接。 要取消链接自动化,请执行以下步骤:

  1. Test Manager 中打开项目,然后转到“测试用例”。
  2. 找到链接到 Studio 的测试用例并将其打开。
  3. 转到“自动化”选项卡,并取消链接 Orchestrator 或 Studio 自动化,如下所示:
    1. 要取消链接 Orchestrator 自动化,请在“已分配的自动化”下选择“取消链接自动化”
    2. 要取消链接 Studio 自动化,请在“Studio 链接信息”下,选择“取消链接”

Automating test cases in Studio Web

You can automate Test Manager test cases directly in Studio Web, within projects of type Tests.

Note: This capability is available only in Test Manager delivered through Test Cloud for EKS/AKS or OpenShift installations.

注意事项

Before starting, review the following considerations:

  • You can only link test cases from Test Manager to Studio Web. Linking from Studio Web to Test Manager is not currently supported.
  • Studio Web projects of type Tests can only be created via Test Manager. You cannot create them in Studio Web directly.
  • You cannot collaborate with other users on the same Studio Web project of type Tests at the same time.
  • There is no bi-directional synchronization between Studio Web and Test Manager.
  • If you delete or move a linked Studio Web test case, an error message appears. You must the relink the test case.

先决条件

Ensure you meet the following conditions:

  • 您有权访问 Studio Web。

    App Test Developers have access to Studio Web.

  • You have permissions to create and edit Studio Web projects.
  • Test Manager is enabled in your Test Cloud organization.

Step 1: Open or create a test case in Test Manager

  1. Navigate to your Test Manager project and go to the Test Cases tab.
  2. Create a new test case, or open an existing one that does not have automation linked.
  3. Open the test case and go to the Automation tab.

Step 2: Link the test case to Studio Web

  1. In the Automation tab, select Automate in Studio Web.

    This opens a panel on the right side to configure the Studio Web automation link.

  2. In the Automate in Studio Web panel, perform the following configurations:
    1. From the Project dropdown list:
      • Select an existing Studio Web project of type Tests.
      • Enter a new project name and select it to create one.
    2. From the Test case dropdown list:
      • Select an existing test case.
      • Enter a new test case name and select it to create one.
    3. Select Add automation.

      Your Test Manager test case is now linked to a test case in Studio Web.

Step 3: Open and automate the test case in Studio Web

  1. In the Automation tab, select Open in Studio Web.

    This opens Studio Web in a new tab, with your linked test case ready to edit.

  2. In the Studio Web project, open the previously created test case.
    1. Build the automated test case using any supported activity packages, including Testing.Activities.
    2. Debug the automation.
    3. When you are ready, publish the Studio Web project, to deploy it to Orchestrator.

      For information on publishing Studio Web projects, refer to Publishing a project.

    Figure 1. Automate in Studio Web panel

Unlinking and deleting Studio Web test cases

The behavior when you unlink or delete a Studio Web test case from a Test Manager test case is:

  1. Unlinking: If you unlink a Studio Web test case, a warning appears before removal.

  2. Deleting: If you delete the Test Manager test case, a warning is shown confirming that the linked Studio Web test case will also be unlinked.

此页面有帮助吗?

获取您需要的帮助
了解 RPA - 自动化课程
UiPath Community 论坛
Uipath Logo
信任与安全
© 2005-2025 UiPath。保留所有权利。