public void testResourceWithExpectedTerminationTimeSet() {
DateTime now = DateTime.now();
Date oldTermDate = new Date(now.plusDays(10).getMillis());
String oldTermReason = "Foo";
int ageThreshold = 5;
Resource resource = new AWSResource().withId("i-12345678").withResourceType(AWSResourceType.INSTANCE)
.withLaunchTime(new Date(now.minusDays(ageThreshold + 1).getMillis()))
.withExpectedTerminationTime(oldTermDate)
.withTerminationReason(oldTermReason);
((AWSResource) resource).setAWSResourceState("running");
int retentionDaysWithOwner = 4;