Skip to content

Test Results removes any line containing org.junit.Test #1804

Closed

Description

package com.example;

import static org.junit.Assert.fail;

import org.junit.Test;

public class T {
    @Test
    public void t() {
        fail("before\n============ org.junit.Test ============\nafter");
    }
}
Image

Activity

  1. github-actions commented on Nov 1, 2025

    @github-actions

    Hi Merlin Volkmer (@Meerschwein), I'm an AI Support assistant here to help with your issue. While the team reviews your request, I wanted to provide some possible tips and documentation that might help you in the meantime.

    It looks like the Test Results panel’s built-in stack-trace filter is stripping out any line that matches org\.junit\..* (including your message line). There’s no user setting yet to toggle this filter, but you can work around it:

    • Escape or obfuscate the string so it no longer matches the filter, e.g.:
      fail("before\norg\.junit\.Test: after".replace("org.junit.Test", "org\.junit\.Test"));
      or insert a zero-width space:
      fail("before\norg.junit.\u200BTest\nafter");

    Track the underlying filter issue here:

    Other references with low confidence

    The team will respond to your issue shortly. I hope these suggestions are helpful in the meantime. If this comment helped you, please give it a 👍. If the suggestion was not helpful or incorrect, please give it a 👎. Your feedback helps us improve!

  2. wenytang-ms commented on Mar 6, 2026

    @wenytang-ms
    Contributor

    we’ve released a prerelease version 0.44.2026030602 of test-runner-for-java, which fixes the issue you reported. Please install this version together with the latest prerelease of vscode-gradle and help verify the fix.

    Merlin Volkmer (@Meerschwein)

    Image
  3. wenytang-ms commented on Mar 9, 2026

    @wenytang-ms
    Contributor

    Merlin Volkmer (@Meerschwein)
    I'm going to close this issue, please reopen this issue once this issue repro.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions