tests
authorAlexey Kudravtsev <cdr@intellij.com>
Fri, 14 Feb 2014 11:46:04 +0000 (15:46 +0400)
committerAlexey Kudravtsev <cdr@intellij.com>
Fri, 14 Feb 2014 11:49:00 +0000 (15:49 +0400)
java/java-tests/testData/codeInsight/daemonCodeAnalyzer/lossyEncoding/Win1251.txt
java/java-tests/testSrc/com/intellij/codeInsight/daemon/LossyEncodingTest.java

index fae5524c2ade12016660512541e36250a72327e8..903905eb5c3a4aef5b695e8cf172283c931ece7a 100644 (file)
@@ -154,19 +154,13 @@ public class LossyEncodingTest extends DaemonAnalyzerTestCase {
   }
 
   public void testDetectWrongEncoding() throws Exception {
-    String threeNotoriousRussianLetters = "\u0416\u041e\u041f";
-    VirtualFile virtualFile = getVirtualFile(BASE_PATH + "/" + "Win1251" + ".txt");
+    VirtualFile virtualFile = getVirtualFile(BASE_PATH + "/" + "Win1251.txt");
     virtualFile.setCharset(CharsetToolkit.UTF8_CHARSET);
     configureByExistingFile(virtualFile);
     final Document document = FileDocumentManager.getInstance().getDocument(virtualFile);
 
     assertFalse(FileDocumentManager.getInstance().isDocumentUnsaved(document));
     assertEquals(CharsetToolkit.UTF8_CHARSET, virtualFile.getCharset());
-    //Charset WINDOWS_1251 = Charset.forName("windows-1251");
-    //virtualFile.setCharset(WINDOWS_1251);
-    //FileDocumentManager.getInstance().saveAllDocuments();  // save in wrong encoding
-    //assertEquals(WINDOWS_1251, virtualFile.getCharset());
-    //assertEquals(threeNotoriousRussianLetters, new String(virtualFile.contentsToByteArray(), WINDOWS_1251));
 
     doHighlighting();
     List<HighlightInfo> infos = DaemonCodeAnalyzerEx.getInstanceEx(getProject()).getFileLevelHighlights(getProject(), getFile());