mirror of
https://gitflic.ru/project/openide/openide.git
synced 2026-08-26 15:27:45 +07:00
EA-36715 (better detect doc comment before conversion)
This commit is contained in:
@@ -0,0 +1,23 @@
|
||||
/*
|
||||
* Copyright 2000-2012 JetBrains s.r.o.
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
class C {
|
||||
/**
|
||||
* Some method.
|
||||
*
|
||||
* @param value some (©)<caret> param.
|
||||
*/
|
||||
abstract void m(int value);
|
||||
}
|
||||
@@ -0,0 +1,23 @@
|
||||
/*
|
||||
* Copyright 2000-2012 JetBrains s.r.o.
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
class C {
|
||||
/**
|
||||
* Some method.
|
||||
*
|
||||
* @param value some (©) param.
|
||||
*/
|
||||
abstract void m(int value);
|
||||
}
|
||||
+11
-18
@@ -13,7 +13,6 @@
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
package com.intellij.codeInsight.intention;
|
||||
|
||||
import com.intellij.JavaTestUtil;
|
||||
@@ -22,7 +21,6 @@ import com.intellij.openapi.vfs.encoding.EncodingManager;
|
||||
import com.intellij.testFramework.fixtures.CodeInsightTestUtil;
|
||||
import com.intellij.testFramework.fixtures.JavaCodeInsightFixtureTestCase;
|
||||
|
||||
|
||||
public class ConvertToBasicLatinTest extends JavaCodeInsightFixtureTestCase {
|
||||
private String myIntention;
|
||||
|
||||
@@ -33,24 +31,19 @@ public class ConvertToBasicLatinTest extends JavaCodeInsightFixtureTestCase {
|
||||
EncodingManager.getInstance().setDefaultCharsetName("UTF-8");
|
||||
}
|
||||
|
||||
public void testConvertCharLiteral() throws Exception {
|
||||
CodeInsightTestUtil.doIntentionTest(myFixture, myIntention, "CharLiteral.java", "CharLiteral_after.java");
|
||||
}
|
||||
|
||||
public void testConvertStringLiteral() throws Exception {
|
||||
CodeInsightTestUtil.doIntentionTest(myFixture, myIntention, "StringLiteral.java", "StringLiteral_after.java");
|
||||
}
|
||||
|
||||
public void testConvertPlainComment() throws Exception {
|
||||
CodeInsightTestUtil.doIntentionTest(myFixture, myIntention, "PlainComment.java", "PlainComment_after.java");
|
||||
}
|
||||
|
||||
public void testConvertDocComment() throws Exception {
|
||||
CodeInsightTestUtil.doIntentionTest(myFixture, myIntention, "DocComment.java", "DocComment_after.java");
|
||||
}
|
||||
|
||||
@Override
|
||||
protected String getTestDataPath() {
|
||||
return JavaTestUtil.getJavaTestDataPath() + "/codeInsight/convertToBasicLatin/";
|
||||
}
|
||||
|
||||
public void testCharLiteral() { doTest(); }
|
||||
public void testStringLiteral() { doTest(); }
|
||||
public void testPlainComment() { doTest(); }
|
||||
public void testDocComment() { doTest(); }
|
||||
public void testDocTag() { doTest(); }
|
||||
|
||||
private void doTest() {
|
||||
final String name = getTestName(false);
|
||||
CodeInsightTestUtil.doIntentionTest(myFixture, myIntention, name + ".java", name + "_after.java");
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user