Package org.assertj.core.util

Examples of org.assertj.core.util.CaseInsensitiveStringComparator


  private ErrorMessageFactory factory;

  @Before
  public void setUp() {
  factory = shouldHaveComparableElementsAccordingToGivenComparator(array("b", "c", "a"),
                                                                   new CaseInsensitiveStringComparator());
  }
View Full Code Here


    objectsWithCustomComparisonStrategy = new Objects(customComparisonStrategy);
    objectsWithCustomComparisonStrategy.failures = failures;
  }

  protected Comparator<?> comparatorForCustomComparisonStrategy() {
    return new CaseInsensitiveStringComparator();
  }
View Full Code Here

public class ShouldBeSortedAccordingToComparator_create_Test {

  @Test
  public void should_create_error_message_with_comparator() {
    ErrorMessageFactory factory = shouldBeSortedAccordingToGivenComparator(1, array("b", "c", "A"),
        new CaseInsensitiveStringComparator());
    String message = factory.create(new TestDescription("Test"), new StandardRepresentation());
    assertEquals(
        "[Test] \ngroup is not sorted according to 'CaseInsensitiveStringComparator' comparator because element 1:\n <\"c\">\nis not less or equal than element 2:\n <\"A\">\ngroup was:\n <[\"b\", \"c\", \"A\"]>",
        message);
  }
View Full Code Here

TOP

Related Classes of org.assertj.core.util.CaseInsensitiveStringComparator

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.