Skip to content

[Bug]: Test methods added under a wrong codeunit in the AL Test Tool page #4039

@adrogin

Description

@adrogin

Describe the issue

When multiple tests methods are added to a test codeunit which is already published and added to a test suite, new test cases can land in another codeunit in the AL Test Tool page.

Expected behavior

Test methods must be shown under the codeunit which publishes these methods.

Steps to reproduce

  1. Create two test codeunits: "Test Codeunit 1" and "Test Codeunit 2", each with two test methods.
  2. Publish the test app and add the new codeunits to a test suite.
    Image

Image

  1. Add a few more test methods to the codeunit 1 (I did 5 more - "TestF" through "TestJ"). Publish the app.

Image

  1. Select Codeunit 1 in the test suite and push "Update Test Methods".
    Result: Test F is added under Codeunit 1, whilst all other methods sit under the Codeunit 2, although all methods are published by codeunit 1.

Image

If I now press "Update Test Methods" on the Codeunit 1 again, it fails:

Image

Additional context

No response

I will provide a fix for a bug

  • I will provide a fix for a bug

Metadata

Metadata

Assignees

No one assigned

    Labels

    ApprovedThe issue is approvedIntegrationGitHub request for Integration area

    Type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions