001/*
002 * Copyright (c) 2014, 2014, Oracle and/or its affiliates. All rights reserved.
003 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
004 *
005 * This code is free software; you can redistribute it and/or modify it
006 * under the terms of the GNU General Public License version 2 only, as
007 * published by the Free Software Foundation.
008 *
009 * This code is distributed in the hope that it will be useful, but WITHOUT
010 * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
011 * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
012 * version 2 for more details (a copy is included in the LICENSE file that
013 * accompanied this code).
014 *
015 * You should have received a copy of the GNU General Public License version
016 * 2 along with this work; if not, write to the Free Software Foundation,
017 * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
018 *
019 * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
020 * or visit www.oracle.com if you need additional information or have any
021 * questions.
022 */
023package com.oracle.mxtool.junit;
024
025import java.io.*;
026
027import org.junit.runner.*;
028import org.junit.runner.notification.*;
029
030public class MxRunListenerDecorator implements MxRunListener {
031
032    private final MxRunListener l;
033
034    public MxRunListenerDecorator(MxRunListener l) {
035        this.l = l;
036    }
037
038    @Override
039    public void testRunStarted(Description description) {
040        l.testRunStarted(description);
041    }
042
043    @Override
044    public void testRunFinished(Result result) {
045        l.testRunFinished(result);
046    }
047
048    @Override
049    public void testAssumptionFailure(Failure failure) {
050        l.testAssumptionFailure(failure);
051    }
052
053    @Override
054    public void testIgnored(Description description) {
055        l.testIgnored(description);
056    }
057
058    @Override
059    public void testClassStarted(Class<?> clazz) {
060        l.testClassStarted(clazz);
061    }
062
063    @Override
064    public void testClassFinished(Class<?> clazz) {
065        l.testClassFinished(clazz);
066    }
067
068    @Override
069    public void testStarted(Description description) {
070        l.testStarted(description);
071    }
072
073    @Override
074    public void testFinished(Description description) {
075        l.testFinished(description);
076    }
077
078    @Override
079    public void testFailed(Failure failure) {
080        l.testFailed(failure);
081    }
082
083    @Override
084    public void testSucceeded(Description description) {
085        l.testSucceeded(description);
086    }
087
088    @Override
089    public PrintStream getWriter() {
090        return l.getWriter();
091    }
092
093    public void testClassFinishedDelimiter() {
094        l.testClassFinishedDelimiter();
095    }
096
097    public void testClassStartedDelimiter() {
098        l.testClassStartedDelimiter();
099    }
100
101    public void testStartedDelimiter() {
102        l.testStartedDelimiter();
103    }
104
105    public void testFinishedDelimiter() {
106        l.testFinishedDelimiter();
107    }
108
109}