mirror of
https://gitflic.ru/project/openide/openide.git
synced 2026-09-27 10:03:11 +07:00
tests moved to xml-tests
This commit is contained in:
@@ -0,0 +1,37 @@
|
||||
package com.intellij.editor;
|
||||
|
||||
import com.intellij.testFramework.EditorTestUtil;
|
||||
import com.intellij.testFramework.LightCodeInsightTestCase;
|
||||
import com.intellij.testFramework.PlatformTestUtil;
|
||||
import org.jetbrains.annotations.NotNull;
|
||||
|
||||
import java.io.File;
|
||||
|
||||
/**
|
||||
* @author Rustam Vishnyakov
|
||||
*/
|
||||
public class XmlEditorTest extends LightCodeInsightTestCase {
|
||||
private String getTestFilePath(boolean isOriginal) {
|
||||
return "/xml/tests/testData/editor/" + getTestName(true) + (isOriginal ? ".xml" : "_after.xml") ;
|
||||
}
|
||||
|
||||
public void testEnterPerformance() throws Exception {
|
||||
configureByFile(getTestFilePath(true));
|
||||
EditorTestUtil.performTypingAction(myEditor, '\n');
|
||||
PlatformTestUtil.assertTiming("PHP editor performance", 7500, 1, new Runnable() {
|
||||
public void run() {
|
||||
for (int i = 0; i < 3; i ++) {
|
||||
EditorTestUtil.performTypingAction(myEditor, '\n');
|
||||
}
|
||||
}
|
||||
});
|
||||
checkResultByFile(getTestFilePath(false));
|
||||
}
|
||||
|
||||
@NotNull
|
||||
@Override
|
||||
protected String getTestDataPath() {
|
||||
return PlatformTestUtil.getCommunityPath().replace(File.separatorChar, '/');
|
||||
}
|
||||
|
||||
}
|
||||
File diff suppressed because it is too large
Load Diff
File diff suppressed because it is too large
Load Diff
Reference in New Issue
Block a user