Class ShouldHavePropertyOrField

java.lang.Object
org.assertj.core.error.BasicErrorMessageFactory
org.assertj.core.error.ShouldHavePropertyOrField
All Implemented Interfaces:
ErrorMessageFactory

public class ShouldHavePropertyOrField extends BasicErrorMessageFactory
Creates an error message indicating that an assertion that verifies that a class has a given field/property.
Author:
Libor Ondrusek
  • Method Details

    • shouldHavePropertyOrField

      public static ErrorMessageFactory shouldHavePropertyOrField(Object actual, String name)
      Parameters:
      actual - the actual value in the failed assertion.
      name - expected name of field for this class
      Returns:
      the created ErrorMessageFactory.