Assert.assertTrue(testErrorBuilder.hasCause());
Assert.assertNotNull(testErrorBuilder.getCause());
Assert.assertTrue(testErrorBuilder.hasMessage$());
Assert.assertNotNull(testErrorBuilder.getMessage$());
TestError testError = testErrorBuilder.build();
Assert.assertEquals("value", testError.getValue());
Assert.assertEquals("value", testError.getMessage());
Assert.assertEquals("message$", testError.getMessage$());
// Test copy constructor
Assert.assertEquals(testErrorBuilder,
TestError.newBuilder(testErrorBuilder));
Assert.assertEquals(testErrorBuilder, TestError.newBuilder(testError));
TestError error = new TestError("value", new NullPointerException());
error.setMessage$("message");
Assert.assertEquals(error,
TestError.newBuilder().setValue("value").
setCause(new NullPointerException()).setMessage$("message").build());
// Test clear