mirror of
https://gitflic.ru/project/openide/openide.git
synced 2025-12-15 11:53:49 +07:00
[lombok] MoveInitializerToConstructorAction: do not warn when all the constructors are synthetic
Fixes IDEA-313384 Lombok vs. Move initializer to constructor GitOrigin-RevId: d5ceb52fec3937178b41adf156b29a8a35ceee75
This commit is contained in:
committed by
intellij-monorepo-bot
parent
50f2f5e439
commit
44ce06450e
@@ -0,0 +1,28 @@
|
||||
package de.plushnikov.intellij.plugin.inspection;
|
||||
|
||||
import com.intellij.testFramework.LightProjectDescriptor;
|
||||
import com.intellij.testFramework.fixtures.LightJavaCodeInsightFixtureTestCase;
|
||||
import de.plushnikov.intellij.plugin.LombokTestUtil;
|
||||
import org.jetbrains.annotations.NotNull;
|
||||
|
||||
|
||||
public class LombokMoveInitializerToConstructorTest extends LightJavaCodeInsightFixtureTestCase {
|
||||
@Override
|
||||
protected @NotNull LightProjectDescriptor getProjectDescriptor() {
|
||||
return LombokTestUtil.LOMBOK_DESCRIPTOR;
|
||||
}
|
||||
|
||||
public void testMoveInitializerToConstructor() {
|
||||
myFixture.configureByText("Test.java", """
|
||||
import lombok.AllArgsConstructor;
|
||||
|
||||
@AllArgsConstructor
|
||||
public class Main {
|
||||
int x;
|
||||
int y = <caret>3;
|
||||
}
|
||||
""");
|
||||
assertEmpty(myFixture.filterAvailableIntentions("Move initializer to constructor"));
|
||||
}
|
||||
|
||||
}
|
||||
Reference in New Issue
Block a user