Skip to content

Commit

Permalink
Make isElementOfCustomAssert protected
Browse files Browse the repository at this point in the history
  • Loading branch information
joel-costigliola committed Nov 11, 2020
1 parent e78f410 commit 4e04c29
Showing 1 changed file with 2 additions and 4 deletions.
6 changes: 2 additions & 4 deletions src/main/java/org/assertj/core/api/AbstractAssert.java
Original file line number Diff line number Diff line change
Expand Up @@ -280,12 +280,10 @@ private boolean isAssertjAssertClass() {
return getClass().getName().startsWith(ORG_ASSERTJ);
}

private boolean isElementOfCustomAssert(StackTraceElement stackTraceElement) {
protected boolean isElementOfCustomAssert(StackTraceElement stackTraceElement) {
Class<?> currentAssertClass = getClass();
while (currentAssertClass != AbstractAssert.class) {
if (stackTraceElement.getClassName().equals(currentAssertClass.getName())) {
return true;
}
if (stackTraceElement.getClassName().equals(currentAssertClass.getName())) return true;
currentAssertClass = currentAssertClass.getSuperclass();
}
return false;
Expand Down

0 comments on commit 4e04c29

Please sign in to comment.