Location via proxy:   [ UP ]  
[Report a bug]   [Manage cookies]                
Skip to content

Commit ae861eb

Browse files
simplify test
1 parent 4b6312f commit ae861eb

20 files changed

+18
-91
lines changed

src/test/java/com/fishercoder/_291Test.java

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -6,9 +6,6 @@
66

77
import static junit.framework.TestCase.assertEquals;
88

9-
/**
10-
* Created by stevesun on 6/6/17.
11-
*/
129
public class _291Test {
1310
private static _291.Solution1 solution1;
1411

src/test/java/com/fishercoder/_294Test.java

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -6,9 +6,6 @@
66

77
import static org.junit.Assert.assertEquals;
88

9-
/**
10-
* Created by stevesun on 5/29/17.
11-
*/
129
public class _294Test {
1310
private static _294.Solution1 solution1;
1411

src/test/java/com/fishercoder/_340Test.java

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -6,9 +6,6 @@
66

77
import static org.junit.Assert.assertEquals;
88

9-
/**
10-
* Created by stevesun on 6/10/17.
11-
*/
129
public class _340Test {
1310
private static _340.Solution1 solution1;
1411
private static _340.Solution2 solution2;

src/test/java/com/fishercoder/_358Test.java

Lines changed: 17 additions & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -4,30 +4,27 @@
44
import org.junit.BeforeClass;
55
import org.junit.Test;
66

7-
/**
8-
* Created by stevesun on 6/8/17.
9-
*/
107
public class _358Test {
118

12-
private static _358.Solution1 solution1;
9+
private static _358.Solution1 solution1;
1310

14-
@BeforeClass
15-
public static void setup() {
16-
solution1 = new _358.Solution1();
17-
}
11+
@BeforeClass
12+
public static void setup() {
13+
solution1 = new _358.Solution1();
14+
}
1815

19-
@Test
20-
public void test1() {
21-
System.out.println(solution1.rearrangeString("aabbcc", 3));
22-
}
16+
@Test
17+
public void test1() {
18+
System.out.println(solution1.rearrangeString("aabbcc", 3));
19+
}
2320

24-
@Test
25-
public void test2() {
26-
System.out.println(solution1.rearrangeString("aaabc", 3));
27-
}
21+
@Test
22+
public void test2() {
23+
System.out.println(solution1.rearrangeString("aaabc", 3));
24+
}
2825

29-
@Test
30-
public void test3() {
31-
System.out.println(solution1.rearrangeString("aaadbbcc", 2));
32-
}
26+
@Test
27+
public void test3() {
28+
System.out.println(solution1.rearrangeString("aaadbbcc", 2));
29+
}
3330
}

src/test/java/com/fishercoder/_459Test.java

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -6,9 +6,6 @@
66

77
import static junit.framework.TestCase.assertEquals;
88

9-
/**
10-
* Created by stevesun on 6/6/17.
11-
*/
129
public class _459Test {
1310
private static _459.Solution1 solution1;
1411
private static _459.Solution2 solution2;

src/test/java/com/fishercoder/_468Test.java

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -6,9 +6,6 @@
66

77
import static org.junit.Assert.assertEquals;
88

9-
/**
10-
* Created by stevesun on 6/10/17.
11-
*/
129
public class _468Test {
1310
private static _468.Solution1 solution1;
1411

src/test/java/com/fishercoder/_493Test.java

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -6,9 +6,6 @@
66

77
import static org.junit.Assert.assertEquals;
88

9-
/**
10-
* Created by stevesun on 6/10/17.
11-
*/
129
public class _493Test {
1310
private static _493.Solution1 solution1;
1411
private static int[] nums;

src/test/java/com/fishercoder/_591Test.java

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -6,9 +6,6 @@
66

77
import static org.junit.Assert.assertEquals;
88

9-
/**
10-
* Created by stevesun on 6/4/17.
11-
*/
129
public class _591Test {
1310
private static _591 test;
1411

src/test/java/com/fishercoder/_604Test.java

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -5,9 +5,6 @@
55

66
import static org.junit.Assert.assertEquals;
77

8-
/**
9-
* Created by stevesun on 6/10/17.
10-
*/
118
public class _604Test {
129
private static _604.StringIterator test;
1310

src/test/java/com/fishercoder/_605Test.java

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -6,9 +6,6 @@
66

77
import static org.junit.Assert.assertEquals;
88

9-
/**
10-
* Created by stevesun on 6/4/17.
11-
*/
129
public class _605Test {
1310
private static _605 test;
1411
private static int[] flowerbed;

src/test/java/com/fishercoder/_606Test.java

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -10,9 +10,6 @@
1010

1111
import static org.junit.Assert.assertEquals;
1212

13-
/**
14-
* Created by stevesun on 6/4/17.
15-
*/
1613
public class _606Test {
1714
private static _606.Solution1 solution1;
1815
private static _606.Solution2 solution2;

src/test/java/com/fishercoder/_611Test.java

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -6,9 +6,6 @@
66

77
import static org.junit.Assert.assertEquals;
88

9-
/**
10-
* Created by stevesun on 6/11/17.
11-
*/
129
public class _611Test {
1310
private static _611 test;
1411
private static int[] nums;
Lines changed: 1 addition & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,5 @@
11
package com.fishercoder;
22

3-
import com.fishercoder.common.classes.TreeNode;
43
import com.fishercoder.common.utils.TreeUtils;
54
import com.fishercoder.solutions._617;
65
import org.junit.BeforeClass;
@@ -10,15 +9,8 @@
109

1110
import static junit.framework.TestCase.assertEquals;
1211

13-
/**
14-
* Created by stevesun on 6/10/17.
15-
*/
1612
public class _617Test {
1713
private static _617.Solution1 solution1;
18-
private static TreeNode t1;
19-
private static TreeNode t2;
20-
private static TreeNode actual;
21-
private static TreeNode expected;
2214

2315
@BeforeClass
2416
public static void setup() {
@@ -27,15 +19,7 @@ public static void setup() {
2719

2820
@Test
2921
public void test1() {
30-
t1 = TreeUtils.constructBinaryTree(Arrays.asList(1, 3, 2, 5));
31-
32-
t2 = TreeUtils.constructBinaryTree(Arrays.asList(2, 1, 3, null, 4, null, 7));
33-
34-
expected = TreeUtils.constructBinaryTree(Arrays.asList(3, 4, 5, 5, 4, null, 7));
35-
36-
actual = solution1.mergeTrees(t1, t2);
37-
38-
assertEquals(expected, actual);
22+
assertEquals(TreeUtils.constructBinaryTree(Arrays.asList(3, 4, 5, 5, 4, null, 7)), solution1.mergeTrees(TreeUtils.constructBinaryTree(Arrays.asList(1, 3, 2, 5)), TreeUtils.constructBinaryTree(Arrays.asList(2, 1, 3, null, 4, null, 7))));
3923
}
4024

4125
}

src/test/java/com/fishercoder/_621Test.java

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -6,9 +6,6 @@
66

77
import static org.junit.Assert.assertEquals;
88

9-
/**
10-
* Created by stevesun on 6/19/17.
11-
*/
129
public class _621Test {
1310
private static _621.Solution1 solution1;
1411
private static char[] tasks;

src/test/java/com/fishercoder/_631Test.java

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -5,9 +5,6 @@
55

66
import static junit.framework.TestCase.assertEquals;
77

8-
/**
9-
* Created by stevesun on 7/26/17.
10-
*/
118
public class _631Test {
129
private static _631.Excel excel;
1310

src/test/java/com/fishercoder/_645Test.java

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -6,9 +6,6 @@
66

77
import static org.junit.Assert.assertArrayEquals;
88

9-
/**
10-
* Created by stevesun on 7/23/17.
11-
*/
129
public class _645Test {
1310
private static _645 test;
1411
private static int[] nums;

src/test/java/com/fishercoder/_648Test.java

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -9,9 +9,6 @@
99

1010
import static org.junit.Assert.assertEquals;
1111

12-
/**
13-
* Created by stevesun on 7/24/17.
14-
*/
1512
public class _648Test {
1613
private static _648 test;
1714
private static List<String> dict;

src/test/java/com/fishercoder/_650Test.java

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -6,9 +6,6 @@
66

77
import static org.junit.Assert.assertEquals;
88

9-
/**
10-
* Created by stevesun on 7/30/17.
11-
*/
129
public class _650Test {
1310
private static _650 test;
1411

src/test/java/com/fishercoder/_651Test.java

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -6,9 +6,6 @@
66

77
import static org.junit.Assert.assertEquals;
88

9-
/**
10-
* Created by stevesun on 7/30/17.
11-
*/
129
public class _651Test {
1310
private static _651 test;
1411

src/test/java/com/fishercoder/_652Test.java

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -12,9 +12,6 @@
1212

1313
import static org.junit.Assert.assertEquals;
1414

15-
/**
16-
* Created by stevesun on 7/30/17.
17-
*/
1815
public class _652Test {
1916
private static _652 test;
2017
private static List<TreeNode> expected;

0 commit comments

Comments
 (0)