From 6fb3266ea61a97e9107ee41499c8bfab5f978964 Mon Sep 17 00:00:00 2001 From: Dmitry Jemerov Date: Mon, 28 Sep 2009 17:26:28 +0400 Subject: [PATCH 1/3] add runtime dependency on jaxen, remove obsolete module components --- RegExpSupport/RegExpSupport.iml | 188 ++------------------------------ 1 file changed, 9 insertions(+), 179 deletions(-) diff --git a/RegExpSupport/RegExpSupport.iml b/RegExpSupport/RegExpSupport.iml index 5be88be26f77..4bc457ed7ac9 100644 --- a/RegExpSupport/RegExpSupport.iml +++ b/RegExpSupport/RegExpSupport.iml @@ -14,185 +14,15 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - + + + + + + + + + From e1f6f338639f18ed73ed25808972213d3194ab18 Mon Sep 17 00:00:00 2001 From: unknown Date: Mon, 28 Sep 2009 17:12:53 +0400 Subject: [PATCH 2/3] close streams in finally blocks --- .../src/com/intellij/xml/actions/xmlbeans/FileUtils.java | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/xml/impl/src/com/intellij/xml/actions/xmlbeans/FileUtils.java b/xml/impl/src/com/intellij/xml/actions/xmlbeans/FileUtils.java index cf91e78d3b10..391f63f880dc 100644 --- a/xml/impl/src/com/intellij/xml/actions/xmlbeans/FileUtils.java +++ b/xml/impl/src/com/intellij/xml/actions/xmlbeans/FileUtils.java @@ -50,8 +50,12 @@ public class FileUtils { public static void saveText(VirtualFile virtualFile, String text) throws IOException { OutputStream outputStream = virtualFile.getOutputStream(virtualFile); - FileUtil.copy(new ByteArrayInputStream(text.getBytes(virtualFile.getCharset().name())), outputStream); - outputStream.close(); + try { + FileUtil.copy(new ByteArrayInputStream(text.getBytes(virtualFile.getCharset().name())), outputStream); + } + finally { + outputStream.close(); + } } public static boolean copyFile(File in, File out) { From 116ab70528ce3e297adb24627dea02d0baff9ef4 Mon Sep 17 00:00:00 2001 From: Dmitry Jemerov Date: Mon, 28 Sep 2009 17:59:56 +0400 Subject: [PATCH 3/3] fix case of testdata --- .../com/intellij/codeInspection/EmptyMethodTest.java | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/java/java-tests/testSrc/com/intellij/codeInspection/EmptyMethodTest.java b/java/java-tests/testSrc/com/intellij/codeInspection/EmptyMethodTest.java index 0474e20d913c..48db4be7acae 100644 --- a/java/java-tests/testSrc/com/intellij/codeInspection/EmptyMethodTest.java +++ b/java/java-tests/testSrc/com/intellij/codeInspection/EmptyMethodTest.java @@ -19,18 +19,18 @@ public class EmptyMethodTest extends InspectionTestCase { private void doTest(final boolean checkRange) throws Exception { final EmptyMethodInspection tool = new EmptyMethodInspection(); - doTest("emptyMethod/" + getTestName(false), tool, checkRange); + doTest("emptyMethod/" + getTestName(true), tool, checkRange); } - public void testsuperCall() throws Exception { + public void testSuperCall() throws Exception { doTest(); } - public void testsuperCallByRange() throws Exception { + public void testSuperCallByRange() throws Exception { doTest(true); } - public void testexternalOverride() throws Exception { + public void testExternalOverride() throws Exception { doTest(); } @@ -42,7 +42,7 @@ public class EmptyMethodTest extends InspectionTestCase { doTest(true); } - public void testsuperFromAnotherPackageCall() throws Exception { + public void testSuperFromAnotherPackageCall() throws Exception { doTest(); } }