Replace assertThat(x.equals(y)) with assertThat(x).isEqualTo(y)
Search for : assertThat\((.+)\.equals\((\w+)\)\)\.isTrue\(\) Replace with : assertThat($1).isEqualTo($2) Search for : assertThat\((.+)\.equals\((\w+)\)\)\.isFalse\(\) Replace with : assertThat($1).isNotEqualTo($2) Closes gh-31763
This commit is contained in:
committed by
Brian Clozel
parent
e2852e7355
commit
7b16ef90f1
@@ -141,7 +141,7 @@ public class ComposablePointcutTests {
|
||||
|
||||
pc1.intersection(GETTER_METHOD_MATCHER);
|
||||
|
||||
assertThat(pc1.equals(pc2)).isFalse();
|
||||
assertThat(pc1).isNotEqualTo(pc2);
|
||||
assertThat(pc1.hashCode()).isNotEqualTo(pc2.hashCode());
|
||||
|
||||
pc2.intersection(GETTER_METHOD_MATCHER);
|
||||
|
||||
@@ -110,8 +110,8 @@ public class MethodMatchersTests {
|
||||
public void testUnionEquals() {
|
||||
MethodMatcher first = MethodMatchers.union(MethodMatcher.TRUE, MethodMatcher.TRUE);
|
||||
MethodMatcher second = new ComposablePointcut(MethodMatcher.TRUE).union(new ComposablePointcut(MethodMatcher.TRUE)).getMethodMatcher();
|
||||
assertThat(first.equals(second)).isTrue();
|
||||
assertThat(second.equals(first)).isTrue();
|
||||
assertThat(first).isEqualTo(second);
|
||||
assertThat(second).isEqualTo(first);
|
||||
}
|
||||
|
||||
@Test
|
||||
|
||||
Reference in New Issue
Block a user