Package org.approvej.approve
Record Class TestMethod.SpockTestMethod
java.lang.Object
java.lang.Record
org.approvej.approve.TestMethod.SpockTestMethod
- Record Components:
method
- the potential testMethod
- All Implemented Interfaces:
TestMethod
- Enclosing interface:
TestMethod
TestMethod
implementation for Spock.-
Nested Class Summary
Nested classes/interfaces inherited from interface org.approvej.approve.TestMethod
TestMethod.JUnitTestMethod, TestMethod.SpockTestMethod, TestMethod.TestNGTestMethod
-
Constructor Summary
ConstructorsConstructorDescriptionSpockTestMethod
(Method method) Creates an instance of aSpockTestMethod
record class. -
Method Summary
Modifier and TypeMethodDescriptionfinal boolean
Indicates whether some other object is "equal to" this one.final int
hashCode()
Returns a hash code value for this object.method()
Returns the value of themethod
record component.Returns all test relatedAnnotation
s of theTestMethod
.Returns the name of the test case.Class
<?> Returns theClass
of theTestMethod
.final String
toString()
Returns a string representation of this record class.
-
Constructor Details
-
SpockTestMethod
Creates an instance of aSpockTestMethod
record class.- Parameters:
method
- the value for themethod
record component
-
-
Method Details
-
testCaseName
Description copied from interface:TestMethod
Returns the name of the test case.- Specified by:
testCaseName
in interfaceTestMethod
- Returns:
- the name of test case
-
testClass
Description copied from interface:TestMethod
Returns theClass
of theTestMethod
.- Specified by:
testClass
in interfaceTestMethod
- Returns:
- the
Class
of theTestMethod
-
testAnnotations
Description copied from interface:TestMethod
Returns all test relatedAnnotation
s of theTestMethod
.- Specified by:
testAnnotations
in interfaceTestMethod
- Returns:
- all test related
Annotation
s of theTestMethod
-
toString
Returns a string representation of this record class. The representation contains the name of the class, followed by the name and value of each of the record components. -
hashCode
public final int hashCode()Returns a hash code value for this object. The value is derived from the hash code of each of the record components. -
equals
Indicates whether some other object is "equal to" this one. The objects are equal if the other object is of the same class and if all the record components are equal. All components in this record class are compared withObjects::equals(Object,Object)
. -
method
Returns the value of themethod
record component.- Specified by:
method
in interfaceTestMethod
- Returns:
- the value of the
method
record component
-