1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20 package com.google.checkstyle.test.chapter4formatting.rule4861blockcommentstyle;
21
22 import org.junit.jupiter.api.Test;
23
24 import com.google.checkstyle.test.base.AbstractGoogleModuleTestSupport;
25
26 public class BlockCommentStyleTest extends AbstractGoogleModuleTestSupport {
27
28 @Override
29 protected String getPackageLocation() {
30 return "com/google/checkstyle/test/chapter4formatting/rule4861blockcommentstyle";
31 }
32
33 @Test
34 public void testCommentIsAtTheEndOfBlock() throws Exception {
35 verifyWithWholeConfig(getPath("InputCommentsIndentationCommentIsAtTheEndOfBlock.java"));
36 }
37
38 @Test
39 public void testCommentIsAtTheEndOfBlockFormatted() throws Exception {
40 verifyWithWholeConfig(
41 getPath("InputFormattedCommentsIndentationCommentIsAtTheEndOfBlock.java"));
42 }
43
44 @Test
45 public void testCommentIsInsideSwitchBlock() throws Exception {
46 verifyWithWholeConfig(getPath("InputCommentsIndentationInSwitchBlock.java"));
47 }
48
49 @Test
50 public void testCommentIsInsideSwitchBlockFormatted() throws Exception {
51 verifyWithWholeConfig(getPath("InputFormattedCommentsIndentationInSwitchBlock.java"));
52 }
53
54 @Test
55 public void testCommentIsInsideEmptyBlock() throws Exception {
56 verifyWithWholeConfig(getPath("InputCommentsIndentationInEmptyBlock.java"));
57 }
58
59 @Test
60 public void testCommentIsInsideEmptyBlockFormatted() throws Exception {
61 verifyWithWholeConfig(getPath("InputFormattedCommentsIndentationInEmptyBlock.java"));
62 }
63
64 @Test
65 public void testSurroundingCode() throws Exception {
66 verifyWithWholeConfig(getPath("InputCommentsIndentationSurroundingCode.java"));
67 }
68
69 @Test
70 public void testSurroundingCodeFormatted() throws Exception {
71 verifyWithWholeConfig(getPath("InputFormattedCommentsIndentationSurroundingCode.java"));
72 }
73
74 }