Top Description Methods
org.junit.jupiter.api

public Interface NamedExecutable

extends Named<Executable>, Executable
Annotations
@FunctionalInterface
@API
status:MAINTAINED
since:5.13.3
Static Imports
org.apiguardian.api.API.Status.MAINTAINED

NamedExecutable joins Executable and Named in a one self-typed functional interface.

The default implementation of getName() returns the result of calling Object#toString() on the implementing instance but may be overridden by concrete implementations to provide a more meaningful name.

It is recommended to implement this interface using a record type.

Since
5.11
See Also
DynamicTest#stream(Stream), DynamicTest#stream(Iterator)

Method Summary

Modifier and TypeMethod and Description
public default String
getName()

Implements org.junit.jupiter.api.Named.getName.

Get the name of the payload.

public default Executable
getPayload()

Implements org.junit.jupiter.api.Named.getPayload.

Get the payload.

Inherited from org.junit.jupiter.api.function.Executable:
execute
Inherited from org.junit.jupiter.api.Named:
namedof

Method Detail

getNameback to summary
public default String getName()

Implements org.junit.jupiter.api.Named.getName.

Doc from org.junit.jupiter.api.Named.getName.

Get the name of the payload.

Annotations
@Override
getPayloadback to summary
public default Executable getPayload()

Implements org.junit.jupiter.api.Named.getPayload.

Doc from org.junit.jupiter.api.Named.getPayload.

Get the payload.

Annotations
@Override