Skip to content

Commit

Permalink
Update dependencies - fixes
Browse files Browse the repository at this point in the history
  • Loading branch information
mkondratek committed Oct 4, 2022
1 parent 0277ac3 commit 46b6bb5
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -117,7 +117,7 @@ public void inner_classes_should_not_be_instantiated_from_constructor_of_enclosi
new DescribedPredicate<JavaConstructorCall>(
"an inner class is instantiated in a constructor of the enclosing class") {
@Override
public boolean apply(JavaConstructorCall input) {
public boolean test(JavaConstructorCall input) {
if (input.getOrigin().isConstructor()) {
JavaClass constructingClass = input.getOriginOwner();
JavaClass constructedClass = input.getTargetOwner();
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -30,15 +30,15 @@ public void actions_overriding_onUpdate_should_call_super_onUpdate() {
.areNotAssignableFrom(com.virtuslab.gitmachete.frontend.actions.base.BaseProjectDependentAction.class)
.and(new DescribedPredicate<JavaClass>("override onUpdate method") {
@Override
public boolean apply(JavaClass input) {
public boolean test(JavaClass input) {
return input.getMethods().stream().anyMatch(method -> method.getName().equals("onUpdate"));
}
})
.should()
.callMethodWhere(
new DescribedPredicate<JavaMethodCall>("name is onUpdate and owner is the direct superclass") {
@Override
public boolean apply(JavaMethodCall input) {
public boolean test(JavaMethodCall input) {
JavaCodeUnit origin = input.getOrigin(); // where is the method called from?
AccessTarget.MethodCallTarget target = input.getTarget(); // where is the method declared?

Expand Down

0 comments on commit 46b6bb5

Please sign in to comment.