Home | History | Annotate | Download | only in base
      1 /*
      2  * Copyright (c) 2007 Mockito contributors
      3  * This program is made available under the terms of the MIT License.
      4  */
      5 
      6 package org.mockito.exceptions.base;
      7 
      8 import org.mockito.internal.exceptions.stacktrace.ConditionalStackTraceFilter;
      9 
     10 
     11 
     12 public class MockitoAssertionError extends AssertionError {
     13 
     14     private static final long serialVersionUID = 1L;
     15     private StackTraceElement[] unfilteredStackTrace;
     16 
     17     public MockitoAssertionError(String message) {
     18         super(message);
     19 
     20         unfilteredStackTrace = getStackTrace();
     21 
     22         ConditionalStackTraceFilter filter = new ConditionalStackTraceFilter();
     23         filter.filter(this);
     24     }
     25 
     26     public StackTraceElement[] getUnfilteredStackTrace() {
     27         return unfilteredStackTrace;
     28     }
     29 }