소스 검색

Test update 1

Tennessee Gibbs 6 년 전
부모
커밋
0806385551
2개의 변경된 파일62개의 추가작업 그리고 66개의 파일을 삭제
  1. 8
    8
      CoreTest.java
  2. 54
    58
      package.bluej

+ 8
- 8
CoreTest.java 파일 보기

@@ -87,18 +87,18 @@ public class CoreTest
87 87
     }
88 88
 
89 89
     @Test
90
-    public void squareRoot()
90
+    public void testsquareRoot()
91 91
     {
92 92
         //expected
93
-        double expected = 1.4;
93
+        double expected = 3.0;
94 94
         //actual
95
-        double actual = test.squareRoot(2.0);
95
+        double actual = test.squareRoot(9.0);
96 96
         //assertion
97 97
         assertEquals(expected, actual, 0.1);
98 98
     }
99 99
 
100 100
     @Test
101
-    public void exponentiation()
101
+    public void testexponentiation()
102 102
     {
103 103
         //expected
104 104
         double expected = 4;
@@ -109,7 +109,7 @@ public class CoreTest
109 109
     }
110 110
 
111 111
     @Test
112
-    public void inverse()
112
+    public void testinverse()
113 113
     {
114 114
         //expected
115 115
         double expected = 0.25;
@@ -120,12 +120,12 @@ public class CoreTest
120 120
     }
121 121
 
122 122
     @Test
123
-    public void reverse()
123
+    public void testreverse()
124 124
     {
125 125
         //expected
126
-        double expected = 0.25;
126
+        double expected = -4.0;
127 127
         //actual
128
-        double actual = test.inverse(4.0);
128
+        double actual = test.reverse(4.0);
129 129
         //assertion
130 130
         assertEquals(expected, actual, 0.1);
131 131
     }

+ 54
- 58
package.bluej 파일 보기

@@ -1,41 +1,44 @@
1 1
 #BlueJ package file
2
-dependency1.from=MainApplication
3
-dependency1.to=Console
2
+dependency1.from=Calculator
3
+dependency1.to=Display
4 4
 dependency1.type=UsesDependency
5
-dependency2.from=MainApplication
6
-dependency2.to=Calculator
5
+dependency2.from=Calculator
6
+dependency2.to=Console
7 7
 dependency2.type=UsesDependency
8
-dependency3.from=CoreTest
8
+dependency3.from=Calculator
9 9
 dependency3.to=Core
10 10
 dependency3.type=UsesDependency
11
-dependency4.from=Calculator
12
-dependency4.to=Display
11
+dependency4.from=MainApplication
12
+dependency4.to=Console
13 13
 dependency4.type=UsesDependency
14
-dependency5.from=Calculator
15
-dependency5.to=Console
14
+dependency5.from=MainApplication
15
+dependency5.to=Calculator
16 16
 dependency5.type=UsesDependency
17
-dependency6.from=Calculator
18
-dependency6.to=Core
17
+dependency6.from=Core
18
+dependency6.to=Display
19 19
 dependency6.type=UsesDependency
20 20
 dependency7.from=Core
21 21
 dependency7.to=Console
22 22
 dependency7.type=UsesDependency
23
+dependency8.from=CoreTest
24
+dependency8.to=Core
25
+dependency8.type=UsesDependency
23 26
 editor.fx.0.height=722
24 27
 editor.fx.0.width=800
25
-editor.fx.0.x=867
26
-editor.fx.0.y=-805
28
+editor.fx.0.x=-133
29
+editor.fx.0.y=-1023
27 30
 objectbench.height=101
28 31
 objectbench.width=677
29 32
 package.divider.horizontal=0.6
30
-package.divider.vertical=0.8459343794579173
31
-package.editor.height=586
33
+package.divider.vertical=0.8470254957507082
34
+package.editor.height=591
32 35
 package.editor.width=1034
33
-package.editor.x=138
34
-package.editor.y=-854
35
-package.frame.height=759
36
+package.editor.x=465
37
+package.editor.y=-1037
38
+package.frame.height=764
36 39
 package.frame.width=1160
37
-package.numDependencies=7
38
-package.numTargets=10
40
+package.numDependencies=8
41
+package.numTargets=9
39 42
 package.showExtends=true
40 43
 package.showUses=true
41 44
 project.charset=UTF-8
@@ -49,16 +52,8 @@ target1.name=CoreTest
49 52
 target1.showInterface=false
50 53
 target1.type=UnitTestTargetJunit4
51 54
 target1.width=80
52
-target1.x=530
53
-target1.y=230
54
-target10.association=DisplayTest
55
-target10.height=50
56
-target10.name=Display
57
-target10.showInterface=false
58
-target10.type=ClassTarget
59
-target10.width=80
60
-target10.x=40
61
-target10.y=310
55
+target1.x=420
56
+target1.y=130
62 57
 target2.height=50
63 58
 target2.name=ScientificTest
64 59
 target2.showInterface=false
@@ -67,53 +62,54 @@ target2.width=80
67 62
 target2.x=530
68 63
 target2.y=130
69 64
 target3.height=50
70
-target3.name=Memory
65
+target3.name=Calculator
71 66
 target3.showInterface=false
72 67
 target3.type=ClassTarget
73
-target3.width=80
74
-target3.x=140
75
-target3.y=480
68
+target3.width=90
69
+target3.x=290
70
+target3.y=70
76 71
 target4.height=50
77
-target4.name=Calculator
72
+target4.name=Console
78 73
 target4.showInterface=false
79 74
 target4.type=ClassTarget
80
-target4.width=90
81
-target4.x=290
82
-target4.y=70
75
+target4.width=80
76
+target4.x=120
77
+target4.y=300
78
+target5.association=ScientificTest
83 79
 target5.height=50
84
-target5.name=Console
80
+target5.name=Scientific
85 81
 target5.showInterface=false
86 82
 target5.type=ClassTarget
87 83
 target5.width=80
88
-target5.x=70
89
-target5.y=390
90
-target6.association=ScientificTest
84
+target5.x=500
85
+target5.y=160
91 86
 target6.height=50
92
-target6.name=Scientific
87
+target6.name=DisplayTest
93 88
 target6.showInterface=false
94
-target6.type=ClassTarget
89
+target6.type=UnitTestTargetJunit4
95 90
 target6.width=80
96
-target6.x=500
97
-target6.y=160
91
+target6.x=480
92
+target6.y=40
98 93
 target7.height=50
99
-target7.name=DisplayTest
94
+target7.name=MainApplication
100 95
 target7.showInterface=false
101
-target7.type=UnitTestTargetJunit4
102
-target7.width=80
96
+target7.type=ClassTarget
97
+target7.width=120
103 98
 target7.x=70
104
-target7.y=280
99
+target7.y=70
100
+target8.association=CoreTest
105 101
 target8.height=50
106
-target8.name=MainApplication
102
+target8.name=Core
107 103
 target8.showInterface=false
108 104
 target8.type=ClassTarget
109
-target8.width=120
110
-target8.x=70
111
-target8.y=70
112
-target9.association=CoreTest
105
+target8.width=80
106
+target8.x=390
107
+target8.y=160
108
+target9.association=DisplayTest
113 109
 target9.height=50
114
-target9.name=Core
110
+target9.name=Display
115 111
 target9.showInterface=false
116 112
 target9.type=ClassTarget
117 113
 target9.width=80
118
-target9.x=500
119
-target9.y=260
114
+target9.x=450
115
+target9.y=70