File tree Expand file tree Collapse file tree 2 files changed +13
-4
lines changed
kata/8-kyu/up-and-down-the-string-grows Expand file tree Collapse file tree 2 files changed +13
-4
lines changed Original file line number Diff line number Diff line change 1- class StrangeString {
2- static final String STRANGE_STRING = "ß" ;
3-
4- private StrangeString () {}
1+ interface StrangeString {
2+ String STRANGE_STRING = "ß" ;
53}
Original file line number Diff line number Diff line change 11import static org .junit .jupiter .api .Assertions .assertEquals ;
2+ import static org .junit .jupiter .api .Assertions .assertTrue ;
23
4+ import java .nio .file .Files ;
5+ import java .nio .file .Path ;
6+ import java .nio .file .Paths ;
37import org .junit .jupiter .api .Test ;
48
59class SolutionTest {
@@ -8,4 +12,11 @@ void sample() {
812 String upDown = StrangeString .STRANGE_STRING .toUpperCase ().toLowerCase ();
913 assertEquals (StrangeString .STRANGE_STRING .length () + 1 , upDown .length ());
1014 }
15+
16+ @ Test
17+ void solutionSize () throws Exception {
18+ Path current = Paths .get ("" ).toAbsolutePath ();
19+ Path solution = current .resolve ("main/StrangeString.java" );
20+ assertTrue (Files .size (solution ) < 81 , "Solution should be 80 characters max." );
21+ }
1122}
You can’t perform that action at this time.
0 commit comments