Right Curly Check compilable UT inputs
This commit is contained in:
parent
647e2e37cb
commit
7f0ec27579
|
|
@ -121,7 +121,7 @@ public class RightCurlyCheckTest extends BaseCheckTestSupport
|
|||
final String[] expected = {
|
||||
"35:43: '}' should be alone on a line.",
|
||||
"41:71: '}' should be alone on a line.",
|
||||
"46:25: '}' should be alone on a line.",
|
||||
"47:25: '}' should be alone on a line.",
|
||||
};
|
||||
verify(mCheckConfig, getPath("InputRightCurlyLineBreakBefore.java"), expected);
|
||||
}
|
||||
|
|
@ -133,7 +133,7 @@ public class RightCurlyCheckTest extends BaseCheckTestSupport
|
|||
"24:33: '}' should have line break before.",
|
||||
"32:44: '}' should have line break before.",
|
||||
"32:63: '}' should have line break before.",
|
||||
"50:48: '}' should have line break before.",
|
||||
"52:56: '}' should have line break before.",
|
||||
};
|
||||
verify(mCheckConfig, getPath("InputRightCurlyLineBreakBefore.java"), expected);
|
||||
}
|
||||
|
|
|
|||
|
|
@ -1,3 +1,4 @@
|
|||
package com.puppycrawl.tools.checkstyle;
|
||||
abstract class CharSequenceReader{
|
||||
|
||||
abstract void moveTo(double deltaX, double deltaY);
|
||||
|
|
|
|||
|
|
@ -5,7 +5,7 @@ import java.lang.annotation.Target;
|
|||
import java.util.ArrayList;
|
||||
import java.util.List;
|
||||
|
||||
class InputLeftCurlyOther
|
||||
class InputRightCurlyLineBreakBefore
|
||||
{
|
||||
/** @see test method **/
|
||||
int foo() throws InterruptedException
|
||||
|
|
@ -41,13 +41,15 @@ class InputLeftCurlyOther
|
|||
for (int k = 0; k < 1; k++) { String innerBlockVariable = ""; }
|
||||
|
||||
for (int k = 0; k < 1; k++) {}
|
||||
return a;
|
||||
}
|
||||
|
||||
static { int x = 1; }
|
||||
|
||||
void method2()
|
||||
{
|
||||
if (flag) { System.err.println("foo"); }
|
||||
boolean flag = false;
|
||||
if (flag) { System.err.println("foo"); }
|
||||
}
|
||||
}
|
||||
|
||||
|
|
@ -56,9 +58,9 @@ class Absent_CustomFieldSerializer {
|
|||
public static void serialize() {}
|
||||
}
|
||||
|
||||
class Absent_CustomFieldSerializer
|
||||
class Absent_CustomFieldSerializer10
|
||||
{
|
||||
public Absent_CustomFieldSerializer() {}
|
||||
public Absent_CustomFieldSerializer10() {}
|
||||
}
|
||||
|
||||
class EmptyClass {}
|
||||
|
|
|
|||
Loading…
Reference in New Issue