Skip to content

Detect when toString is the same but only newline characters differ #509

@JakeWharton

Description

@JakeWharton

This can be a common occurrence with code generation where you have platform-specific golden files or strings as your expects, but platform-agnostic code generation that uses either CRLF or LF depending on the host. Since these render the same visually and will be the same source type, there is no way to tell what's wrong from the error message.

Truth does this, and it's glorious.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions