From 15b8640bba6a3ef4b377ce2768685f89045f7c55 Mon Sep 17 00:00:00 2001 From: Sergey Ignatov Date: Thu, 30 Mar 2017 23:56:08 +0300 Subject: [PATCH] move performance test to htmltools, because of js and css inside --- .../psi/formatter/HtmlFormatterTest.java | 14 +- .../psi/formatter/html/performance.html | 1 - .../psi/formatter/html/performance_after.html | 372 -- .../html/quotesReplacementPerformance.html | 5213 ---------------- .../quotesReplacementPerformance_after.html | 5231 ----------------- 5 files changed, 7 insertions(+), 10824 deletions(-) delete mode 100644 xml/tests/testData/psi/formatter/html/performance.html delete mode 100644 xml/tests/testData/psi/formatter/html/performance_after.html delete mode 100644 xml/tests/testData/psi/formatter/html/quotesReplacementPerformance.html delete mode 100644 xml/tests/testData/psi/formatter/html/quotesReplacementPerformance_after.html diff --git a/xml/tests/src/com/intellij/psi/formatter/HtmlFormatterTest.java b/xml/tests/src/com/intellij/psi/formatter/HtmlFormatterTest.java index 23fa64bc1b30..4bd980e2dc2a 100644 --- a/xml/tests/src/com/intellij/psi/formatter/HtmlFormatterTest.java +++ b/xml/tests/src/com/intellij/psi/formatter/HtmlFormatterTest.java @@ -262,6 +262,13 @@ public class HtmlFormatterTest extends XmlFormatterTestBase { doTestPerformance("html reformat with range", 5000, null); } + public void testQuotesReplacementPerformance() throws Exception { + doTestPerformance("Quotes replacement", 1500, (settings)->{ + settings.HTML_QUOTE_STYLE = CodeStyleSettings.QuoteStyle.Single; + settings.HTML_ENFORCE_QUOTES = true; + }); + } + public void doTestPerformance(@NotNull String message, int expectedTime, OptionsSetup optionsSetup) throws Exception { CodeStyleSettings settings = new CodeStyleSettings(); if (optionsSetup != null) optionsSetup.setupOptions(settings); @@ -505,13 +512,6 @@ public class HtmlFormatterTest extends XmlFormatterTestBase { } } - public void testQuotesReplacementPerformance() throws Exception { - doTestPerformance("Quotes replacement", 1500, (settings)->{ - settings.HTML_QUOTE_STYLE = CodeStyleSettings.QuoteStyle.Single; - settings.HTML_ENFORCE_QUOTES = true; - }); - } - public void testWeb18213() { doTextTest( "
\n" + diff --git a/xml/tests/testData/psi/formatter/html/performance.html b/xml/tests/testData/psi/formatter/html/performance.html deleted file mode 100644 index c6ce8b123a8c..000000000000 --- a/xml/tests/testData/psi/formatter/html/performance.html +++ /dev/null @@ -1 +0,0 @@ -yandeks

segodnya v novostyach 16:58

  1. 1. k 12 godam katorzhnych rabot prigovoreny dve amerikanskie zhurnalistki
  2. 2. najdeno 17 tel s razbivshegosya v atlantike aerobusa Air France
  3. 3. sud prigovoril ubijcu moskovskoj shkoljnicy k 23 godam lisheniya svobody
  4. 4. kazhdyj desyatyj rossijskij vypusknik provalil ege po geografii
  5. 5. dmitrij mezencev utverzhden na postu gubernatora �?rkutskoj oblasti
  1. 1. General Motors na tri nedeli ostanovil konvejer peterburgskogo zavoda
  2. 2. v peterburge vruczili premiyu «nacionaljnyj bestseller»
  3. 3. fejerverka na denj rossii v peterburge ne budet
  4. 4. czinovnikov krasnogvardejskogo rajona nakazali za korotkie peremeny v shkolach
  5. 5. russkij muzej pokazhet sto shedevrov na ulicach peterburga

esche boljshe novych vakansij v pitere

moj krug — novyj vitok vashej karjery

yandeks

poiskkartymarketnovostislovariblogivideokartinki
rasshirennyj poisk

poczta

zavesti pocztovyj yaschik

\ No newline at end of file diff --git a/xml/tests/testData/psi/formatter/html/performance_after.html b/xml/tests/testData/psi/formatter/html/performance_after.html deleted file mode 100644 index 28b5e3d3b362..000000000000 --- a/xml/tests/testData/psi/formatter/html/performance_after.html +++ /dev/null @@ -1,372 +0,0 @@ - -yandeks - - - - - - - - - - - - -
- - -

segodnya v novostyach 16:58

- -
-
    -
  1. 1. k 12 godam katorzhnych rabot prigovoreny - dve amerikanskie zhurnalistki -
  2. 2. najdeno 17 tel s razbivshegosya v - atlantike aerobusa Air France -
  3. 3. sud prigovoril ubijcu moskovskoj shkoljnicy k - 23 godam lisheniya svobody -
  4. 4. kazhdyj desyatyj rossijskij vypusknik provalil - ege po geografii -
  5. 5. dmitrij mezencev utverzhden na - postu gubernatora �?rkutskoj oblasti -
-
-
-
    -
  1. 1. General Motors na tri nedeli ostanovil - konvejer peterburgskogo zavoda -
  2. 2. v peterburge vruczili premiyu - «nacionaljnyj bestseller» -
  3. 3. fejerverka na denj rossii - v peterburge ne budet -
  4. 4. czinovnikov krasnogvardejskogo rajona nakazali - za korotkie peremeny v shkolach -
  5. 5. russkij muzej pokazhet sto - shedevrov na ulicach peterburga -
-
-
- - -
- - -
-

- esche boljshe novych vakansij v pitere

-

moj krug — novyj vitok vashej karjery

-
-

yandeks

-
-
- - -
poisk - karty - market - novosti - slovari - blogi - video - kartinki - - -
- - -
- - - -
- -
- - rasshirennyj poisk -
-
- -
-
- - - - -
-
-

poczta

-
-
-
-
-
- - -
- - - -
-

- zavesti - pocztovyj yaschik

-
-

fotki

- - -
-
-
-
fotka
-
-
-
-
-
- - -
- -
-
-
- \ No newline at end of file diff --git a/xml/tests/testData/psi/formatter/html/quotesReplacementPerformance.html b/xml/tests/testData/psi/formatter/html/quotesReplacementPerformance.html deleted file mode 100644 index f0768855a57a..000000000000 --- a/xml/tests/testData/psi/formatter/html/quotesReplacementPerformance.html +++ /dev/null @@ -1,5213 +0,0 @@ - - - - JavaScript Courses - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - -
- -
- -
- - -
- -

- Welcome to the acme Library -

- -
-
-

- This is a sample catalog of all the courses we offer. Browse by topic or difficulty. Sign up - today and get access to our entire library. acme students get access to workshops, bonus - content, conferences, and more. -

-

Ready to start learning?

-

- acme offers a 7 day free trial for new students. Get access to 1000s of - hours of content. Learn to code, land your dream job. -

- Start - Your Free Trial - - - - -
-
- Welcome -
-
- -
- - -
- - - - - -
-
-

JavaScript

-

JavaScript is a programming language that allows you to add - interactivity to websites. It can be used to create interactive effects on web pages.

-
- - -
- -
- -
-

Whoops! Perhaps you can try a broader search.

-

Reset all filters

-
-
-
-

Upcoming Releases

-

The following items are scheduled to be released soon. You can also visit our content roadmap for more info.

-
- -
- - -
- -
- -
-
- -
- - - -
- - - - - - - - -
- - -
- - - - - - - - - - - - - \ No newline at end of file diff --git a/xml/tests/testData/psi/formatter/html/quotesReplacementPerformance_after.html b/xml/tests/testData/psi/formatter/html/quotesReplacementPerformance_after.html deleted file mode 100644 index 9213559283aa..000000000000 --- a/xml/tests/testData/psi/formatter/html/quotesReplacementPerformance_after.html +++ /dev/null @@ -1,5231 +0,0 @@ - - - - JavaScript Courses - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - -
- -
- -
- - -
- -

- Welcome to the acme Library -

- -
-
-

- This is a sample catalog of all the courses we offer. Browse by topic or difficulty. Sign up - today and get access to our entire library. acme students get access to workshops, bonus - content, conferences, and more. -

-

Ready to start learning?

-

- acme offers a 7 day free trial for new students. Get access to 1000s of - hours of content. Learn to code, land your dream job. -

- Start - Your Free Trial - - - - -
-
- Welcome -
-
- -
- - -
- - - - - -
-
-

JavaScript

-

JavaScript is a programming language that allows you to add - interactivity to websites. It can be used to create interactive effects on web pages.

-
- - -
- -
- -
-

Whoops! Perhaps you can try a broader search.

-

Reset all filters

-
-
-
-

Upcoming Releases

-

The following items are scheduled to be released soon. You can also visit our content roadmap for more info.

-
- -
- - -
- -
- -
-
- -
- - - -
- - - - - - - - -
- - -
- - - - - - - - - - - - - \ No newline at end of file