@DataProvider(value = { "true", "false" }) @Test public void kitchen_sink_constructor_sets_fields_as_expected(boolean useStaticFactory) { Deque<Span> spanStackMock = mock(Deque.class); Map<String, String> mdcInfoMock = mock(Map.class); FailureCallbackWithTracing instance = (useStaticFactory) ? withTracing(failureCallbackMock, spanStackMock, mdcInfoMock) : new FailureCallbackWithTracing(failureCallbackMock, spanStackMock, mdcInfoMock); assertThat(instance.origFailureCallback).isSameAs(failureCallbackMock); assertThat(instance.spanStackForExecution).isEqualTo(spanStackMock); assertThat(instance.mdcContextMapForExecution).isEqualTo(mdcInfoMock); }
public static FailureCallbackWithTracing withTracing(FailureCallback origFailureCallback) { return new FailureCallbackWithTracing(origFailureCallback); }
FailureCallbackWithTracing implements FailureCallback { public static FailureCallbackWithTracing withTracing(FailureCallback origFailureCallback) { return new FailureCallbackWithTracing(origFailureCallback); } }
FailureCallbackWithTracing implements FailureCallback { public static FailureCallbackWithTracing withTracing(FailureCallback origFailureCallback) { return new FailureCallbackWithTracing(origFailureCallback); } FailureCallbackWithTracing(FailureCallback origFailureCallback);  FailureCallbackWithTracing(FailureCallback origFailureCallback,
                                      Pair<Deque<Span>, Map<String, String>> originalThreadInfo);  FailureCallbackWithTracing(FailureCallback origFailureCallback,
                                      Deque<Span> spanStackForExecution,
                                      Map<String, String> mdcContextMapForExecution); }
FailureCallbackWithTracing implements FailureCallback { public static FailureCallbackWithTracing withTracing(FailureCallback origFailureCallback) { return new FailureCallbackWithTracing(origFailureCallback); } FailureCallbackWithTracing(FailureCallback origFailureCallback);  FailureCallbackWithTracing(FailureCallback origFailureCallback,
                                      Pair<Deque<Span>, Map<String, String>> originalThreadInfo);  FailureCallbackWithTracing(FailureCallback origFailureCallback,
                                      Deque<Span> spanStackForExecution,
                                      Map<String, String> mdcContextMapForExecution); static FailureCallbackWithTracing withTracing(FailureCallback origFailureCallback); static FailureCallbackWithTracing withTracing(FailureCallback origFailureCallback,
                                                         Pair<Deque<Span>, Map<String, String>> originalThreadInfo); static FailureCallbackWithTracing withTracing(FailureCallback origFailureCallback,
                                                         Deque<Span> spanStackForExecution,
                                                         Map<String, String> mdcContextMapForExecution); @Override @SuppressWarnings("deprecation") void onFailure(Throwable ex); }
FailureCallbackWithTracing implements FailureCallback { public static FailureCallbackWithTracing withTracing(FailureCallback origFailureCallback) { return new FailureCallbackWithTracing(origFailureCallback); } FailureCallbackWithTracing(FailureCallback origFailureCallback);  FailureCallbackWithTracing(FailureCallback origFailureCallback,
                                      Pair<Deque<Span>, Map<String, String>> originalThreadInfo);  FailureCallbackWithTracing(FailureCallback origFailureCallback,
                                      Deque<Span> spanStackForExecution,
                                      Map<String, String> mdcContextMapForExecution); static FailureCallbackWithTracing withTracing(FailureCallback origFailureCallback); static FailureCallbackWithTracing withTracing(FailureCallback origFailureCallback,
                                                         Pair<Deque<Span>, Map<String, String>> originalThreadInfo); static FailureCallbackWithTracing withTracing(FailureCallback origFailureCallback,
                                                         Deque<Span> spanStackForExecution,
                                                         Map<String, String> mdcContextMapForExecution); @Override @SuppressWarnings("deprecation") void onFailure(Throwable ex);  }