Package org.assertj.core.error
Class ShouldHavePackage
java.lang.Object
org.assertj.core.error.BasicErrorMessageFactory
org.assertj.core.error.ShouldHavePackage
- All Implemented Interfaces:
ErrorMessageFactory
Creates an error message indicating that a
Class
should have a given package.- Author:
- Matteo Mirk
-
Field Summary
Fields inherited from class org.assertj.core.error.BasicErrorMessageFactory
arguments, format
-
Method Summary
Modifier and TypeMethodDescriptionstatic ErrorMessageFactory
shouldHavePackage
(Class<?> actual, Package aPackage) Creates a newShouldHavePackage
with aPackage
instance.static ErrorMessageFactory
shouldHavePackage
(Class<?> actual, String packageName) Creates a newShouldHavePackage
with a package name.Methods inherited from class org.assertj.core.error.BasicErrorMessageFactory
create, create, create, equals, hashCode, toString, unquotedString
-
Method Details
-
shouldHavePackage
Creates a newShouldHavePackage
with aPackage
instance.- Parameters:
actual
- the actual value in the failed assertion.aPackage
- the expected package- Returns:
- the created
ErrorMessageFactory
.
-
shouldHavePackage
Creates a newShouldHavePackage
with a package name.- Parameters:
actual
- the actual value in the failed assertion.packageName
- the expected package name- Returns:
- the created
ErrorMessageFactory
.
-