Replace assertThat(x.iterator().next()) with assertThat(x).element(0)
Search for : assertThat\((.+).iterator\(\).next\(\)\) Replace with : assertThat($1).element(0)
This commit is contained in:
@@ -47,7 +47,7 @@ public abstract class AbstractCacheOperationTests<O extends JCacheOperation<?>>
|
||||
assertThat(operation.getCacheName()).as("Wrong cache name").isEqualTo("simpleCache");
|
||||
assertThat(operation.getAnnotations()).as("Unexpected number of annotation on " + operation.getMethod())
|
||||
.hasSize(1);
|
||||
assertThat(operation.getAnnotations().iterator().next()).as("Wrong method annotation").isEqualTo(operation.getCacheAnnotation());
|
||||
assertThat(operation.getAnnotations()).element(0).as("Wrong method annotation").isEqualTo(operation.getCacheAnnotation());
|
||||
|
||||
assertThat(operation.getCacheResolver()).as("cache resolver should be set").isNotNull();
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user