public void shouldGetAllMeasurements() {
assertThat(collection1.getAuditRecords().size(), is(equalTo(result1.size())));
Map map = new HashMap();
Iterator iterator = result1.iterator();
while (iterator.hasNext()) {
AuditRecordRepresentation rep = (AuditRecordRepresentation) iterator.next();
map.put(rep.getId(), rep);
}
iterator = collection1.getAuditRecords().iterator();
while (iterator.hasNext()) {
AuditRecordRepresentation orig = (AuditRecordRepresentation) map.get(((AuditRecordRepresentation) iterator.next()).getId());
assertThat(orig, is(notNullValue()));
}
}