com.google.code.jetm.maven.data
Class AggregateSummaryTest

java.lang.Object
  extended by com.google.code.jetm.maven.data.AggregateSummaryTest

public class AggregateSummaryTest
extends Object

Unit tests for AggregateSummary.

Author:
jrh3k5

Field Summary
 org.junit.rules.ExpectedException expected
          A Rule used to test for thrown exceptions.
 
Constructor Summary
AggregateSummaryTest()
           
 
Method Summary
 void testAdd()
          Test the summary of two aggregates in a single AggregateSummary object.
 void testCompareTo()
          Test the comparison of two AggregateSummary objects.
 void testConstructNullName()
          Given a null name, construction should fail.
 void testEquals()
          Two summaries by the same name should be equal.
 void testEqualsNotAggregateSummary()
          An aggregate summary should not be equal to an object that is not an aggregate summary.
 void testEqualsNull()
          An aggregate summary should not be equal to null.
 void testEqualsSelf()
          An aggregate summary should be equal to itself.
 void testHashCode()
          A summary's hash code should be simply the hash code of its name.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

expected

public org.junit.rules.ExpectedException expected
A Rule used to test for thrown exceptions.

Constructor Detail

AggregateSummaryTest

public AggregateSummaryTest()
Method Detail

testConstructNullName

public void testConstructNullName()
Given a null name, construction should fail.


testEquals

public void testEquals()
Two summaries by the same name should be equal.


testEqualsNotAggregateSummary

public void testEqualsNotAggregateSummary()
An aggregate summary should not be equal to an object that is not an aggregate summary.


testEqualsNull

public void testEqualsNull()
An aggregate summary should not be equal to null.


testEqualsSelf

public void testEqualsSelf()
An aggregate summary should be equal to itself.


testAdd

public void testAdd()
Test the summary of two aggregates in a single AggregateSummary object.


testCompareTo

public void testCompareTo()
Test the comparison of two AggregateSummary objects. Two summaries by the same name should match; those with different names should not match.


testHashCode

public void testHashCode()
A summary's hash code should be simply the hash code of its name.



Copyright © 2011. All Rights Reserved.