@@ -0,0 +1,2718 @@
+// Copyright 2000-2018 JetBrains s.r.o. Use of this source code is governed by the Apache 2.0 license that can be found in the LICENSE file.%0Apackage com.intellij.xml.propertyBased;%0A%0Aimport com.intellij.ide.highlighter.XmlFileType;%0Aimport com.intellij.openapi.fileTypes.FileTypeManager;%0Aimport com.intellij.psi.PsiFile;%0Aimport com.intellij.testFramework.PlatformTestUtil;%0Aimport com.intellij.testFramework.SkipSlowTestLocally;%0Aimport com.intellij.testFramework.fixtures.LightCodeInsightFixtureTestCase;%0Aimport com.intellij.testFramework.propertyBased.CheckHighlighterConsistency;%0Aimport com.intellij.testFramework.propertyBased.MadTestingAction;%0Aimport com.intellij.testFramework.propertyBased.MadTestingUtil;%0Aimport org.jetbrains.annotations.NotNull;%0Aimport org.jetbrains.jetCheck.Generator;%0Aimport org.jetbrains.jetCheck.PropertyChecker;%0A%0Aimport java.io.File;%0Aimport java.util.function.Function;%0Aimport java.util.function.Supplier;%0A%0A@SkipSlowTestLocally%0Apublic class XmlCodeInsightSanityTest extends LightCodeInsightFixtureTestCase %7B%0A%0A  private static final boolean ENABLED = false;%0A%0A  @Override%0A  protected boolean shouldRunTest() %7B%0A    return ENABLED && super.shouldRunTest();%0A  %7D%0A%0A  public void testIncrementalHighlighterUpdate() %7B%0A    PropertyChecker.checkScenarios(actionsOnXmlFiles(CheckHighlighterConsistency.randomEditsWithHighlighterChecks));%0A  %7D%0A%0A  public void testReparse() %7B%0A    PropertyChecker.checkScenarios(actionsOnXmlFiles(MadTestingUtil::randomEditsWithReparseChecks));%0A  %7D%0A%0A  @NotNull%0A  private Supplier%3CMadTestingAction%3E actionsOnXmlFiles(Function%3CPsiFile, Generator%3C? extends MadTestingAction%3E%3E fileActions) %7B%0A    String%5B%5D extensions = FileTypeManager.getInstance().getAssociatedExtensions(XmlFileType.INSTANCE);%0A%0A    return MadTestingUtil.actionsOnFileContents(myFixture,%0A                                                PlatformTestUtil.getCommunityPath().replace(File.separatorChar, '/') +%0A                                                %22/xml/tests/testData%22, // PathManager.getHomePath()%0A                                                f -%3E %7B%0A                                                  String name = f.getName();%0A                                                  for (String extension: extensions) %7B%0A                                                    if (name.endsWith(%22.%22 + extension)) %7B%0A                                                      System.out.println(f.getPath());%0A                                                      return true;%0A                                                    %7D%0A                                                  %7D%0A                                                  return false;%0A                                                %7D, fileActions);%0A  %7D%0A%7D%0A

add XmlCodeInsightSanityTest (disabled)