@Test
public void testValidateAWSDocument() {

    
    StringBuilder errMsg = new StringBuilder(256);
    StringBuilder privateIp = new StringBuilder(64);
    MockInstanceAWSProvider provider = new MockInstanceAWSProvider();
    System.setProperty(InstanceAWSProvider.AWS_PROP_PUBLIC_CERT, "src/test/resources/aws_public.cert");
    provider.initialize("provider", "com.yahoo.athenz.instance.provider.impl.InstanceAWSProvider", null, null);
    
    String bootTime = Timestamp.fromMillis(System.currentTimeMillis() - 100).toString();
    AWSAttestationData data = new AWSAttestationData();
    data.setDocument("{\"accountId\": \"1234\",\"pendingTime\": \""
            + bootTime + "\",\"region\":\"us-west-2\",\"instanceId\": \"i-1234\"}");
    data.setSignature("signature");
    assertTrue(provider.validateAWSDocument("athenz.aws.us-west-2", data,
            "1234", "i-1234", true, privateIp, errMsg));
}