Skip to content

zig test: std.testing.expectEqual error message for the expected value is hard to read #8777

@ZapAnton

Description

@ZapAnton

The error message about the expected value of the expectEqual is printed too close to the name of the failed test.
For example the following test

const testing = @import("std").testing;

test "failing test" {
    const x = 5;
    try testing.expectEqual(x, 2);
}

produces the following line:

expected 5, found 2test "failing test"... FAIL (TestExpectedEqual)

Maybe a single space could be used after the expected 5, found 2?

Zig version: 0.8.0-dev.2237+8eea5eddf

Metadata

Metadata

Assignees

No one assigned

    Labels

    contributor friendlyThis issue is limited in scope and/or knowledge of Zig internals.enhancementSolving this issue will likely involve adding new logic or components to the codebase.standard libraryThis issue involves writing Zig code for the standard library.

    Type

    No type

    Projects

    No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions