org.kuali.rice.krad.service.impl
Class DictionaryValidationServiceImplTest

java.lang.Object
  extended by org.kuali.rice.krad.service.impl.DictionaryValidationServiceImplTest

public class DictionaryValidationServiceImplTest
extends Object

DictionaryValidationServiceImplTest tests DictionaryValidationServiceImpl using the data dictionary configurations in org/kuali/rice/krad/test/datadictionary/validation

Author:
Kuali Rice Team (rice.collab@kuali.org)

Field Summary
protected  DataObjectEntry addressEntry
           
 
Constructor Summary
DictionaryValidationServiceImplTest()
           
 
Method Summary
protected  boolean hasError(DictionaryValidationResult dvr, String attributeName, String errorKey)
          checks whether a DictionaryValidationResult contains errors for a named attribute
 void setUp()
           
 void testCollectionConstraints()
           
 void testInvalidDCAddress()
           
 void testInvalidUSAddress()
           
 void testNoStateNoZipUSAddress()
           
 void testRequiredNestedAttribute()
           
 void testSimpleCaseConstraints()
           
 void testValidNonDCAddress()
           
 void testValidNonUSAddress()
           
 void testValidUSAddress()
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

addressEntry

protected DataObjectEntry addressEntry
Constructor Detail

DictionaryValidationServiceImplTest

public DictionaryValidationServiceImplTest()
Method Detail

setUp

public void setUp()
           throws Exception
Throws:
Exception

testValidNonUSAddress

public void testValidNonUSAddress()

testValidUSAddress

public void testValidUSAddress()

testInvalidUSAddress

public void testInvalidUSAddress()

testValidNonDCAddress

public void testValidNonDCAddress()

testInvalidDCAddress

public void testInvalidDCAddress()

testNoStateNoZipUSAddress

public void testNoStateNoZipUSAddress()

testSimpleCaseConstraints

public void testSimpleCaseConstraints()
                               throws IOException
Throws:
IOException

testRequiredNestedAttribute

public void testRequiredNestedAttribute()
                                 throws IOException
Throws:
IOException

testCollectionConstraints

public void testCollectionConstraints()
                               throws IOException
Throws:
IOException

hasError

protected boolean hasError(DictionaryValidationResult dvr,
                           String attributeName,
                           String errorKey)
checks whether a DictionaryValidationResult contains errors for a named attribute

Parameters:
dvr - - the dictionary validation result
attributeName - - the attribute whose validation errors are being checked
errorKey - - a constant that retrieves an informational message to display to the user
Returns:
true if an error with the error key has been found for the attribute, false otherwise


Copyright © 2005-2012 The Kuali Foundation. All Rights Reserved.