This commit is contained in:
anna
2010-05-21 10:03:10 +04:00
parent 87fb647edb
commit 06e808e881
2 changed files with 3 additions and 32 deletions
@@ -26,8 +26,9 @@ import com.intellij.execution.configurations.ConfigurationPerRunnerSettings;
import com.intellij.execution.configurations.RunnerSettings;
import com.intellij.execution.filters.HyperlinkInfo;
import com.intellij.execution.process.ProcessHandler;
import com.intellij.execution.testframework.*;
import com.intellij.execution.testframework.Printable;
import com.intellij.execution.testframework.Printer;
import com.intellij.execution.testframework.stacktrace.DiffHyperlink;
import com.intellij.execution.testframework.ui.BaseTestsOutputConsoleView;
import com.intellij.execution.testframework.ui.TestResultsPanel;
import com.intellij.execution.ui.ConsoleView;
@@ -187,7 +188,7 @@ public class TestNGConsoleView extends BaseTestsOutputConsoleView {
if (matcher.matches()) {
printables.add(new Chunk(matcher.group(1), ConsoleViewContentType.ERROR_OUTPUT));
//we have an assert with expected/actual, so we parse it out and create a diff hyperlink
TestNGDiffHyperLink link = new TestNGDiffHyperLink(matcher.group(2), matcher.group(3), null, (TestNGConsoleProperties) myProperties) {
DiffHyperlink link = new DiffHyperlink(matcher.group(2), matcher.group(3), null) {
protected String getTitle() {
//TODO should do some more farting about to find the equality assertion that failed and show that as title
return result.getTestClass() + '#' + result.getMethod() + "() failed";
@@ -1,30 +0,0 @@
/*
* Copyright 2000-2009 JetBrains s.r.o.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package com.theoryinpractice.testng.ui;
import com.intellij.execution.testframework.stacktrace.DiffHyperlink;
import com.theoryinpractice.testng.model.TestNGConsoleProperties;
/**
* @author Hani Suleiman Date: Dec 1, 2006 Time: 12:14:04 PM
*/
public class TestNGDiffHyperLink extends DiffHyperlink {
public TestNGDiffHyperLink(final String expected, final String actual, final String filePath, final TestNGConsoleProperties consoleProperties) {
super(expected, actual, filePath);
}
}