com.atlassian.confluence.it
Class Assertions

java.lang.Object
  extended by junit.framework.Assert
      extended by com.atlassian.confluence.it.Assertions

public class Assertions
extends junit.framework.Assert


Constructor Summary
Assertions()
           
 
Method Summary
static
<T> void
assertCollectionContains(Collection<T> actual, T... expected)
          Var-args version of assertCollectionContains(Collection, Collection) with the arguments flipped for this purpose.
static void assertCollectionContains(Collection expected, Collection actual)
          Asserts two collections contain the same elements with the same cardinality, regardless of the order of the items in the collection.
static void assertCollectionsEqual(Collection expected, Collection actual)
           
static void assertContains(String expectedSubstring, String actual)
           
static void assertDoesNotContain(String unexpectedSubstring, String actual)
           
static void assertEndsWith(String expectedSuffix, String actual)
           
static void assertStartsWith(String expectedPrefix, String actual)
           
static void assertWithinRange(int expectedValue, int actualValue, int delta)
           
static void assertWithinRange(long expectedValue, long actualValue, long delta)
           
 
Methods inherited from class junit.framework.Assert
assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertFalse, assertFalse, assertNotNull, assertNotNull, assertNotSame, assertNotSame, assertNull, assertNull, assertSame, assertSame, assertTrue, assertTrue, fail, fail, failNotEquals, failNotSame, failSame, format
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

Assertions

public Assertions()
Method Detail

assertContains

public static void assertContains(String expectedSubstring,
                                  String actual)

assertDoesNotContain

public static void assertDoesNotContain(String unexpectedSubstring,
                                        String actual)

assertEndsWith

public static void assertEndsWith(String expectedSuffix,
                                  String actual)

assertStartsWith

public static void assertStartsWith(String expectedPrefix,
                                    String actual)

assertCollectionsEqual

public static void assertCollectionsEqual(Collection expected,
                                          Collection actual)

assertCollectionContains

public static void assertCollectionContains(Collection expected,
                                            Collection actual)
Asserts two collections contain the same elements with the same cardinality, regardless of the order of the items in the collection.

See Also:
CollectionUtils.isEqualCollection(Collection, Collection)

assertCollectionContains

public static <T> void assertCollectionContains(Collection<T> actual,
                                                T... expected)
Var-args version of assertCollectionContains(Collection, Collection) with the arguments flipped for this purpose.


assertWithinRange

public static void assertWithinRange(int expectedValue,
                                     int actualValue,
                                     int delta)

assertWithinRange

public static void assertWithinRange(long expectedValue,
                                     long actualValue,
                                     long delta)


Copyright © 2003-2012 Atlassian. All Rights Reserved.