mil.dod.th.ose.shared/test/mil/dod/th/ose/shared/TestSharedMessageUtils.java
@Test
    public void testConvertUUIDToProtoUUID()
    {
        UUID testUuid = UUID.randomUUID();
        try
        {
            SharedMessageUtils.convertUUIDToProtoUUID(null);
            fail("Expecting exception");
        }
        catch (IllegalArgumentException e)
        {
            
        }
        
        SharedMessages.UUID convertedUuid = SharedMessageUtils.convertUUIDToProtoUUID(testUuid);
        
        assertThat(testUuid.getLeastSignificantBits(), is(convertedUuid.getLeastSignificantBits()));
        assertThat(testUuid.getMostSignificantBits(), is(convertedUuid.getMostSignificantBits()));        
    }
/**
     * Test and verify that a Java UUID object is properly converted to a google protocol buffer
     * UUID message.
     */
Test and verify that a Java UUID object is properly converted to a google protocol buffer
UUID message.
Test and verify that a Java UUID object is properly converted to a google protocol buffer UUID message .
@Test
    public void testConvertUUIDToProtoUUID()
    {
        UUID testUuid = UUID.randomUUID();
        try
        {
            SharedMessageUtils.convertUUIDToProtoUUID(null);
            fail("Expecting exception");
        }
        catch (IllegalArgumentException e)
        {
        }
        SharedMessages.UUID convertedUuid = SharedMessageUtils.convertUUIDToProtoUUID(testUuid);
        assertThat(testUuid.getLeastSignificantBits(), is(convertedUuid.getLeastSignificantBits()));
        assertThat(testUuid.getMostSignificantBits(), is(convertedUuid.getMostSignificantBits()));        
    }
@ Test public void testConvertUUIDToProtoUUID ( ) { UUID testUuid = UUID . randomUUID ( ) ; try { SharedMessageUtils . convertUUIDToProtoUUID ( null ) ; fail ( "Expecting exception" ) ; } catch ( IllegalArgumentException e ) { } SharedMessages . UUID convertedUuid = SharedMessageUtils . convertUUIDToProtoUUID ( testUuid ) ; assertThat ( testUuid . getLeastSignificantBits ( ) , is ( convertedUuid . getLeastSignificantBits ( ) ) ) ; assertThat ( testUuid . getMostSignificantBits ( ) , is ( convertedUuid . getMostSignificantBits ( ) ) ) ; }
Test and verify that a Java UUID object is properly converted to a google protocol buffer
 UUID message.
Test and verify that a Java UUID object is properly converted to a google protocol buffer UUID message .