From 0543b3b47b6b04e6045f6ad8445be11d4e91a698 Mon Sep 17 00:00:00 2001 From: peter Date: Fri, 24 Mar 2017 13:33:02 +0100 Subject: [PATCH] more warmup in performance XmlEditorTest --- xml/tests/src/com/intellij/editor/XmlEditorTest.java | 6 ++++-- xml/tests/testData/editor/enterPerformance_after.xml | 2 ++ 2 files changed, 6 insertions(+), 2 deletions(-) diff --git a/xml/tests/src/com/intellij/editor/XmlEditorTest.java b/xml/tests/src/com/intellij/editor/XmlEditorTest.java index 3fa13f00492b..73fcd4c7097a 100644 --- a/xml/tests/src/com/intellij/editor/XmlEditorTest.java +++ b/xml/tests/src/com/intellij/editor/XmlEditorTest.java @@ -34,12 +34,14 @@ public class XmlEditorTest extends LightCodeInsightTestCase { public void testEnterPerformance() throws Exception { configureByFile(getTestFilePath(true)); - EditorTestUtil.performTypingAction(myEditor, '\n'); + for (int i = 0; i < 3; i++) { + EditorTestUtil.performTypingAction(myEditor, '\n'); + } PlatformTestUtil.startPerformanceTest("Xml editor enter", 7500, () -> { for (int i = 0; i < 3; i ++) { EditorTestUtil.performTypingAction(myEditor, '\n'); } - }).cpuBound().assertTiming(); + }).cpuBound().attempts(1).assertTiming(); checkResultByFile(getTestFilePath(false)); } diff --git a/xml/tests/testData/editor/enterPerformance_after.xml b/xml/tests/testData/editor/enterPerformance_after.xml index dbc2847af13b..d42a0c63386b 100644 --- a/xml/tests/testData/editor/enterPerformance_after.xml +++ b/xml/tests/testData/editor/enterPerformance_after.xml @@ -19829,6 +19829,8 @@ + +