Skip to content

Remove requirement to not have "/" in test names? (Junit 5) #514

@veeti

Description

@veeti

Fantastic tool, thank you! I only hit a little snag: in my project I already have many Kotest/Junit5 units named after HTTP endpoints such as GET /example, and I'm hitting this error:

Caused by: java.lang.IllegalStateException: Test name cannot contain '/', was ...
	at com.diffplug.selfie.junit5.SnapshotFileProgress.startTest(SnapshotSystemJUnit5.kt:188)

This happens for every test even though they do not invoke Selfie for snapshots. Could this requirement be loosened somehow? For example:

  • Escape the resulting name of snapshot files to remove the slash
  • Do not run this check in tests that do not make use of Selfie

Thank you.

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions