test/org/ohmage/validator/ClassValidatorsTest.java
@Test
	public void testValidateClassRoster() {
		try {
			Assert.assertNull(ClassValidators.validateClassRoster(null));
			Assert.assertNull(ClassValidators.validateClassRoster(new byte[0]));
			
			try {
				ClassValidators.validateClassRole("Invalid value.");
				fail("The class roster was invalid.");
			}
			catch(ValidationException e) {
				// Passed.
			}
			
			// TODO: Create a roster for testing.
		}
		catch(ValidationException e) {
			fail("A validation exception was thrown: " + e.getMessage());
		}
	}
/**
	 * Tests the class roster validator.
	 */
Tests the class roster validator.
Tests the class roster validator .
@Test
	public void testValidateClassRoster() {
		try {
			Assert.assertNull(ClassValidators.validateClassRoster(null));
			Assert.assertNull(ClassValidators.validateClassRoster(new byte[0]));
			try {
				ClassValidators.validateClassRole("Invalid value.");
				fail("The class roster was invalid.");
			}
			catch(ValidationException e) {
			}
		}
		catch(ValidationException e) {
			fail("A validation exception was thrown: " + e.getMessage());
		}
	}
@ Test public void testValidateClassRoster ( ) { try { Assert . assertNull ( ClassValidators . validateClassRoster ( null ) ) ; Assert . assertNull ( ClassValidators . validateClassRoster ( new byte [ 0 ] ) ) ; try { ClassValidators . validateClassRole ( "Invalid value." ) ; fail ( "The class roster was invalid." ) ; } catch ( ValidationException e ) { } } catch ( ValidationException e ) { fail ( "A validation exception was thrown: " + e . getMessage ( ) ) ; } }
Tests the class roster validator.
Tests the class roster validator .
// Passed. // TODO: Create a roster for testing.