org.junit.contrib.truth.subjects
Class IntegerSubject

java.lang.Object
  extended by org.junit.contrib.truth.subjects.Subject<IntegerSubject,Long>
      extended by org.junit.contrib.truth.subjects.IntegerSubject

@GwtCompatible
public class IntegerSubject
extends Subject<IntegerSubject,Long>

Propositions for Integral numeric subjects

Author:
David Saff, Christian Gruber (cgruber@israfil.net)

Nested Class Summary
 
Nested classes/interfaces inherited from class org.junit.contrib.truth.subjects.Subject
Subject.And<C>
 
Constructor Summary
IntegerSubject(FailureStrategy failureStrategy, Integer i)
           
IntegerSubject(FailureStrategy failureStrategy, Long i)
           
 
Method Summary
 Subject.And<IntegerSubject> is(byte other)
           
 Subject.And<IntegerSubject> is(int other)
           
 Subject.And<IntegerSubject> is(short other)
           
 Subject.And<IntegerSubject> isBetween(long lower, long upper)
          Attests that a Subject is exclusively within the lower and upper bounds provided or fails.
 Subject.And<IntegerSubject> isEqualTo(Integer other)
           
 Subject.And<IntegerSubject> isEqualTo(Long other)
           
 Subject.And<IntegerSubject> isInclusivelyInRange(long lower, long upper)
          Attests that a Subject is inclusively within the lower and upper bounds provided or fails.
 Subject.And<IntegerSubject> isNotEqualTo(Integer other)
           
 Subject.And<IntegerSubject> isNotEqualTo(Long other)
           
 
Methods inherited from class org.junit.contrib.truth.subjects.Subject
check, fail, failWithoutSubject, getSubject, is, isA, isEqualTo, isNotA, isNotEqualTo, isNotNull, isNull, nextChain
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

IntegerSubject

public IntegerSubject(FailureStrategy failureStrategy,
                      Long i)

IntegerSubject

public IntegerSubject(FailureStrategy failureStrategy,
                      Integer i)
Method Detail

isInclusivelyInRange

public Subject.And<IntegerSubject> isInclusivelyInRange(long lower,
                                                        long upper)
Attests that a Subject is inclusively within the lower and upper bounds provided or fails.

Throws:
IllegalArgumentException - if the lower bound is greater than the upper.

isBetween

public Subject.And<IntegerSubject> isBetween(long lower,
                                             long upper)
Attests that a Subject is exclusively within the lower and upper bounds provided or fails.

Throws:
IllegalArgumentException - if the lower bound is greater than the upper.

isEqualTo

public Subject.And<IntegerSubject> isEqualTo(Integer other)

isEqualTo

public Subject.And<IntegerSubject> isEqualTo(Long other)

isNotEqualTo

public Subject.And<IntegerSubject> isNotEqualTo(Integer other)

isNotEqualTo

public Subject.And<IntegerSubject> isNotEqualTo(Long other)

is

public Subject.And<IntegerSubject> is(int other)

is

public Subject.And<IntegerSubject> is(short other)

is

public Subject.And<IntegerSubject> is(byte other)


Copyright © 2014. All Rights Reserved.