forked from fishercoder1534/Leetcode
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy path_1062Test.java
More file actions
43 lines (34 loc) · 1018 Bytes
/
_1062Test.java
File metadata and controls
43 lines (34 loc) · 1018 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
package com.fishercoder;
import com.fishercoder.solutions._1062;
import org.junit.BeforeClass;
import org.junit.Ignore;
import org.junit.Test;
import static org.junit.Assert.assertEquals;
@Ignore
public class _1062Test {
private static _1062.Solution1 solution1;
@BeforeClass
public static void setup() {
solution1 = new _1062.Solution1();
}
@Test
public void test1() {
assertEquals(0, (solution1.longestRepeatingSubstring("abcd")));
}
@Test
public void test2() {
assertEquals(2, (solution1.longestRepeatingSubstring("abbaba")));
}
@Test
public void test3() {
assertEquals(3, (solution1.longestRepeatingSubstring("aabcaabdaab")));
}
@Test
public void test4() {
assertEquals(4, (solution1.longestRepeatingSubstring("aaaaa")));
}
@Test
public void test5() {
assertEquals(10, (solution1.longestRepeatingSubstring("aaabaabbbaaabaabbaabbbabbbaaaabbaaaaaabbbaabbbbbbbbbaaaabbabbaba")));
}
}