com.atlassian.jira.rest.client
Class TestUtil

java.lang.Object
  extended by com.atlassian.jira.rest.client.TestUtil

public class TestUtil
extends Object


Constructor Summary
TestUtil()
           
 
Method Summary
static
<E> void
assertEqualsSymmetrical(E a, E b)
           
static void assertErrorCode(int errorCode, Runnable runnable)
           
static void assertErrorCode(int errorCode, String message, Runnable runnable)
           
static void assertErrorCode(javax.ws.rs.core.Response.Status status, Runnable runnable)
           
static void assertErrorCode(javax.ws.rs.core.Response.Status status, String message, Runnable runnable)
           
static void assertErrorCodeWithRegexp(int errorCode, String regExp, Runnable runnable)
           
static void assertErrorCodeWithRegexp(javax.ws.rs.core.Response.Status status, String regexp, Runnable runnable)
           
static
<E> void
assertNotEquals(E a, E b)
           
static
<T extends Throwable>
void
assertThrows(Class<T> clazz, String regexp, Runnable runnable)
           
static String getLastPathSegment(URI uri)
           
static Transition getTransitionByName(Iterable<Transition> transitions, String transitionName)
           
static org.joda.time.DateTime toDateTime(String isoDateTimeSt)
           
static org.joda.time.DateTime toDateTime(String isoDateTimeSt, org.joda.time.DateTimeZone zone)
           
static org.joda.time.DateTime toDateTimeFromIsoDate(String isoDate)
           
static URI toUri(String str)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

TestUtil

public TestUtil()
Method Detail

toUri

public static URI toUri(String str)

toDateTime

public static org.joda.time.DateTime toDateTime(String isoDateTimeSt)

toDateTime

public static org.joda.time.DateTime toDateTime(String isoDateTimeSt,
                                                org.joda.time.DateTimeZone zone)

toDateTimeFromIsoDate

public static org.joda.time.DateTime toDateTimeFromIsoDate(String isoDate)

assertErrorCode

public static void assertErrorCode(int errorCode,
                                   Runnable runnable)

assertThrows

public static <T extends Throwable> void assertThrows(Class<T> clazz,
                                                      String regexp,
                                                      Runnable runnable)

assertErrorCode

public static void assertErrorCode(javax.ws.rs.core.Response.Status status,
                                   String message,
                                   Runnable runnable)

assertErrorCodeWithRegexp

public static void assertErrorCodeWithRegexp(javax.ws.rs.core.Response.Status status,
                                             String regexp,
                                             Runnable runnable)

assertErrorCode

public static void assertErrorCode(javax.ws.rs.core.Response.Status status,
                                   Runnable runnable)

assertErrorCode

public static void assertErrorCode(int errorCode,
                                   String message,
                                   Runnable runnable)

assertErrorCodeWithRegexp

public static void assertErrorCodeWithRegexp(int errorCode,
                                             String regExp,
                                             Runnable runnable)

getLastPathSegment

public static String getLastPathSegment(URI uri)

assertEqualsSymmetrical

public static <E> void assertEqualsSymmetrical(E a,
                                               E b)

assertNotEquals

public static <E> void assertNotEquals(E a,
                                       E b)

getTransitionByName

@Nullable
public static Transition getTransitionByName(Iterable<Transition> transitions,
                                                      String transitionName)


Copyright © 2012 Atlassian Pty Ltd. All Rights Reserved.