Ver código fonte

ONE HUNDREAD PERCENTAGE COVERAGE

Ahmad Rusdi 8 anos atrás
pai
commit
da81b8785d

+ 1
- 1
.idea/compiler.xml Ver arquivo

@@ -10,7 +10,7 @@
10 10
       </profile>
11 11
     </annotationProcessing>
12 12
     <bytecodeTargetLevel>
13
-      <module name="bankaccountlab" target="1.5" />
13
+      <module name="bankaccountlab" target="1.8" />
14 14
     </bytecodeTargetLevel>
15 15
   </component>
16 16
 </project>

+ 124
- 0
.idea/uiDesigner.xml Ver arquivo

@@ -0,0 +1,124 @@
1
+<?xml version="1.0" encoding="UTF-8"?>
2
+<project version="4">
3
+  <component name="Palette2">
4
+    <group name="Swing">
5
+      <item class="com.intellij.uiDesigner.HSpacer" tooltip-text="Horizontal Spacer" icon="/com/intellij/uiDesigner/icons/hspacer.png" removable="false" auto-create-binding="false" can-attach-label="false">
6
+        <default-constraints vsize-policy="1" hsize-policy="6" anchor="0" fill="1" />
7
+      </item>
8
+      <item class="com.intellij.uiDesigner.VSpacer" tooltip-text="Vertical Spacer" icon="/com/intellij/uiDesigner/icons/vspacer.png" removable="false" auto-create-binding="false" can-attach-label="false">
9
+        <default-constraints vsize-policy="6" hsize-policy="1" anchor="0" fill="2" />
10
+      </item>
11
+      <item class="javax.swing.JPanel" icon="/com/intellij/uiDesigner/icons/panel.png" removable="false" auto-create-binding="false" can-attach-label="false">
12
+        <default-constraints vsize-policy="3" hsize-policy="3" anchor="0" fill="3" />
13
+      </item>
14
+      <item class="javax.swing.JScrollPane" icon="/com/intellij/uiDesigner/icons/scrollPane.png" removable="false" auto-create-binding="false" can-attach-label="true">
15
+        <default-constraints vsize-policy="7" hsize-policy="7" anchor="0" fill="3" />
16
+      </item>
17
+      <item class="javax.swing.JButton" icon="/com/intellij/uiDesigner/icons/button.png" removable="false" auto-create-binding="true" can-attach-label="false">
18
+        <default-constraints vsize-policy="0" hsize-policy="3" anchor="0" fill="1" />
19
+        <initial-values>
20
+          <property name="text" value="Button" />
21
+        </initial-values>
22
+      </item>
23
+      <item class="javax.swing.JRadioButton" icon="/com/intellij/uiDesigner/icons/radioButton.png" removable="false" auto-create-binding="true" can-attach-label="false">
24
+        <default-constraints vsize-policy="0" hsize-policy="3" anchor="8" fill="0" />
25
+        <initial-values>
26
+          <property name="text" value="RadioButton" />
27
+        </initial-values>
28
+      </item>
29
+      <item class="javax.swing.JCheckBox" icon="/com/intellij/uiDesigner/icons/checkBox.png" removable="false" auto-create-binding="true" can-attach-label="false">
30
+        <default-constraints vsize-policy="0" hsize-policy="3" anchor="8" fill="0" />
31
+        <initial-values>
32
+          <property name="text" value="CheckBox" />
33
+        </initial-values>
34
+      </item>
35
+      <item class="javax.swing.JLabel" icon="/com/intellij/uiDesigner/icons/label.png" removable="false" auto-create-binding="false" can-attach-label="false">
36
+        <default-constraints vsize-policy="0" hsize-policy="0" anchor="8" fill="0" />
37
+        <initial-values>
38
+          <property name="text" value="Label" />
39
+        </initial-values>
40
+      </item>
41
+      <item class="javax.swing.JTextField" icon="/com/intellij/uiDesigner/icons/textField.png" removable="false" auto-create-binding="true" can-attach-label="true">
42
+        <default-constraints vsize-policy="0" hsize-policy="6" anchor="8" fill="1">
43
+          <preferred-size width="150" height="-1" />
44
+        </default-constraints>
45
+      </item>
46
+      <item class="javax.swing.JPasswordField" icon="/com/intellij/uiDesigner/icons/passwordField.png" removable="false" auto-create-binding="true" can-attach-label="true">
47
+        <default-constraints vsize-policy="0" hsize-policy="6" anchor="8" fill="1">
48
+          <preferred-size width="150" height="-1" />
49
+        </default-constraints>
50
+      </item>
51
+      <item class="javax.swing.JFormattedTextField" icon="/com/intellij/uiDesigner/icons/formattedTextField.png" removable="false" auto-create-binding="true" can-attach-label="true">
52
+        <default-constraints vsize-policy="0" hsize-policy="6" anchor="8" fill="1">
53
+          <preferred-size width="150" height="-1" />
54
+        </default-constraints>
55
+      </item>
56
+      <item class="javax.swing.JTextArea" icon="/com/intellij/uiDesigner/icons/textArea.png" removable="false" auto-create-binding="true" can-attach-label="true">
57
+        <default-constraints vsize-policy="6" hsize-policy="6" anchor="0" fill="3">
58
+          <preferred-size width="150" height="50" />
59
+        </default-constraints>
60
+      </item>
61
+      <item class="javax.swing.JTextPane" icon="/com/intellij/uiDesigner/icons/textPane.png" removable="false" auto-create-binding="true" can-attach-label="true">
62
+        <default-constraints vsize-policy="6" hsize-policy="6" anchor="0" fill="3">
63
+          <preferred-size width="150" height="50" />
64
+        </default-constraints>
65
+      </item>
66
+      <item class="javax.swing.JEditorPane" icon="/com/intellij/uiDesigner/icons/editorPane.png" removable="false" auto-create-binding="true" can-attach-label="true">
67
+        <default-constraints vsize-policy="6" hsize-policy="6" anchor="0" fill="3">
68
+          <preferred-size width="150" height="50" />
69
+        </default-constraints>
70
+      </item>
71
+      <item class="javax.swing.JComboBox" icon="/com/intellij/uiDesigner/icons/comboBox.png" removable="false" auto-create-binding="true" can-attach-label="true">
72
+        <default-constraints vsize-policy="0" hsize-policy="2" anchor="8" fill="1" />
73
+      </item>
74
+      <item class="javax.swing.JTable" icon="/com/intellij/uiDesigner/icons/table.png" removable="false" auto-create-binding="true" can-attach-label="false">
75
+        <default-constraints vsize-policy="6" hsize-policy="6" anchor="0" fill="3">
76
+          <preferred-size width="150" height="50" />
77
+        </default-constraints>
78
+      </item>
79
+      <item class="javax.swing.JList" icon="/com/intellij/uiDesigner/icons/list.png" removable="false" auto-create-binding="true" can-attach-label="false">
80
+        <default-constraints vsize-policy="6" hsize-policy="2" anchor="0" fill="3">
81
+          <preferred-size width="150" height="50" />
82
+        </default-constraints>
83
+      </item>
84
+      <item class="javax.swing.JTree" icon="/com/intellij/uiDesigner/icons/tree.png" removable="false" auto-create-binding="true" can-attach-label="false">
85
+        <default-constraints vsize-policy="6" hsize-policy="6" anchor="0" fill="3">
86
+          <preferred-size width="150" height="50" />
87
+        </default-constraints>
88
+      </item>
89
+      <item class="javax.swing.JTabbedPane" icon="/com/intellij/uiDesigner/icons/tabbedPane.png" removable="false" auto-create-binding="true" can-attach-label="false">
90
+        <default-constraints vsize-policy="3" hsize-policy="3" anchor="0" fill="3">
91
+          <preferred-size width="200" height="200" />
92
+        </default-constraints>
93
+      </item>
94
+      <item class="javax.swing.JSplitPane" icon="/com/intellij/uiDesigner/icons/splitPane.png" removable="false" auto-create-binding="false" can-attach-label="false">
95
+        <default-constraints vsize-policy="3" hsize-policy="3" anchor="0" fill="3">
96
+          <preferred-size width="200" height="200" />
97
+        </default-constraints>
98
+      </item>
99
+      <item class="javax.swing.JSpinner" icon="/com/intellij/uiDesigner/icons/spinner.png" removable="false" auto-create-binding="true" can-attach-label="true">
100
+        <default-constraints vsize-policy="0" hsize-policy="6" anchor="8" fill="1" />
101
+      </item>
102
+      <item class="javax.swing.JSlider" icon="/com/intellij/uiDesigner/icons/slider.png" removable="false" auto-create-binding="true" can-attach-label="false">
103
+        <default-constraints vsize-policy="0" hsize-policy="6" anchor="8" fill="1" />
104
+      </item>
105
+      <item class="javax.swing.JSeparator" icon="/com/intellij/uiDesigner/icons/separator.png" removable="false" auto-create-binding="false" can-attach-label="false">
106
+        <default-constraints vsize-policy="6" hsize-policy="6" anchor="0" fill="3" />
107
+      </item>
108
+      <item class="javax.swing.JProgressBar" icon="/com/intellij/uiDesigner/icons/progressbar.png" removable="false" auto-create-binding="true" can-attach-label="false">
109
+        <default-constraints vsize-policy="0" hsize-policy="6" anchor="0" fill="1" />
110
+      </item>
111
+      <item class="javax.swing.JToolBar" icon="/com/intellij/uiDesigner/icons/toolbar.png" removable="false" auto-create-binding="false" can-attach-label="false">
112
+        <default-constraints vsize-policy="0" hsize-policy="6" anchor="0" fill="1">
113
+          <preferred-size width="-1" height="20" />
114
+        </default-constraints>
115
+      </item>
116
+      <item class="javax.swing.JToolBar$Separator" icon="/com/intellij/uiDesigner/icons/toolbarSeparator.png" removable="false" auto-create-binding="false" can-attach-label="false">
117
+        <default-constraints vsize-policy="0" hsize-policy="0" anchor="0" fill="1" />
118
+      </item>
119
+      <item class="javax.swing.JScrollBar" icon="/com/intellij/uiDesigner/icons/scrollbar.png" removable="false" auto-create-binding="true" can-attach-label="false">
120
+        <default-constraints vsize-policy="6" hsize-policy="0" anchor="0" fill="2" />
121
+      </item>
122
+    </group>
123
+  </component>
124
+</project>

+ 285
- 143
.idea/workspace.xml Ver arquivo

@@ -2,10 +2,14 @@
2 2
 <project version="4">
3 3
   <component name="ChangeListManager">
4 4
     <list default="true" id="4ef4ec73-ddb2-4032-9102-265be266e585" name="Default" comment="">
5
+      <change beforePath="" afterPath="$PROJECT_DIR$/src/main/java/com/zipcodewilmington/bankaccountlab/AccountFactory.java" />
6
+      <change beforePath="" afterPath="$PROJECT_DIR$/src/main/java/com/zipcodewilmington/bankaccountlab/BusinessAccount.java" />
5 7
       <change beforePath="$PROJECT_DIR$/.idea/compiler.xml" afterPath="$PROJECT_DIR$/.idea/compiler.xml" />
6
-      <change beforePath="$PROJECT_DIR$/.idea/misc.xml" afterPath="$PROJECT_DIR$/.idea/misc.xml" />
7 8
       <change beforePath="$PROJECT_DIR$/.idea/workspace.xml" afterPath="$PROJECT_DIR$/.idea/workspace.xml" />
8
-      <change beforePath="$PROJECT_DIR$/pom.xml" afterPath="$PROJECT_DIR$/pom.xml" />
9
+      <change beforePath="$PROJECT_DIR$/src/main/java/com/zipcodewilmington/bankaccountlab/BankAccount.java" afterPath="" />
10
+      <change beforePath="$PROJECT_DIR$/src/main/java/com/zipcodewilmington/bankaccountlab/BuisnessAccount.java" afterPath="" />
11
+      <change beforePath="$PROJECT_DIR$/src/test/java/com/zipcodewilmington/bankaccountlab/AccountTest.java" afterPath="$PROJECT_DIR$/src/test/java/com/zipcodewilmington/bankaccountlab/AccountTest.java" />
12
+      <change beforePath="$PROJECT_DIR$/src/test/java/com/zipcodewilmington/bankaccountlab/BankAccountTest.java" afterPath="" />
9 13
     </list>
10 14
     <ignored path="$PROJECT_DIR$/target/" />
11 15
     <option name="EXCLUDED_CONVERTED_TO_IGNORED" value="true" />
@@ -16,26 +20,35 @@
16 20
     <option name="LAST_RESOLUTION" value="IGNORE" />
17 21
   </component>
18 22
   <component name="CoverageDataManager">
23
+    <SUITE FILE_PATH="coverage/bankaccountlab$AccountTest_addBalanceTest.coverage" NAME="AccountTest.addBalanceTest Coverage Results" MODIFIED="1529018578478" SOURCE_PROVIDER="com.intellij.coverage.DefaultCoverageFileProvider" RUNNER="idea" COVERAGE_BY_TEST_ENABLED="false" COVERAGE_TRACING_ENABLED="false">
24
+      <FILTER>com.zipcodewilmington.bankaccountlab.*</FILTER>
25
+    </SUITE>
19 26
     <SUITE FILE_PATH="coverage/bankaccountlab$AccountTest.coverage" NAME="AccountTest Coverage Results" MODIFIED="1528827497566" SOURCE_PROVIDER="com.intellij.coverage.DefaultCoverageFileProvider" RUNNER="idea" COVERAGE_BY_TEST_ENABLED="false" COVERAGE_TRACING_ENABLED="false">
20 27
       <FILTER>com.zipcodewilmington.bankaccountlab.*</FILTER>
21 28
     </SUITE>
22 29
     <SUITE FILE_PATH="coverage/bankaccountlab$CheckingAccountTest.coverage" NAME="CheckingAccountTest Coverage Results" MODIFIED="1529017865464" SOURCE_PROVIDER="com.intellij.coverage.DefaultCoverageFileProvider" RUNNER="idea" COVERAGE_BY_TEST_ENABLED="false" COVERAGE_TRACING_ENABLED="false">
23 30
       <FILTER>com.zipcodewilmington.bankaccountlab.*</FILTER>
24 31
     </SUITE>
32
+    <SUITE FILE_PATH="coverage/bankaccountlab$BusinessAccountTest_depositMoneyTest.coverage" NAME="BusinessAccountTest.depositMoneyTest Coverage Results" MODIFIED="1529067685775" SOURCE_PROVIDER="com.intellij.coverage.DefaultCoverageFileProvider" RUNNER="idea" COVERAGE_BY_TEST_ENABLED="false" COVERAGE_TRACING_ENABLED="false">
33
+      <FILTER>com.zipcodewilmington.bankaccountlab.*</FILTER>
34
+    </SUITE>
35
+    <SUITE FILE_PATH="coverage/bankaccountlab$AccountTest_subtractBalanceTest.coverage" NAME="AccountTest.subtractBalanceTest Coverage Results" MODIFIED="1529018512099" SOURCE_PROVIDER="com.intellij.coverage.DefaultCoverageFileProvider" RUNNER="idea" COVERAGE_BY_TEST_ENABLED="false" COVERAGE_TRACING_ENABLED="false">
36
+      <FILTER>com.zipcodewilmington.bankaccountlab.*</FILTER>
37
+    </SUITE>
38
+    <SUITE FILE_PATH="coverage/bankaccountlab$com_zipcodewilmington_bankaccountlab_in_bankaccountlab.coverage" NAME="com.zipcodewilmington.bankaccountlab in bankaccountlab Coverage Results" MODIFIED="1529077192621" SOURCE_PROVIDER="com.intellij.coverage.DefaultCoverageFileProvider" RUNNER="idea" COVERAGE_BY_TEST_ENABLED="false" COVERAGE_TRACING_ENABLED="false">
39
+      <FILTER>com.zipcodewilmington.bankaccountlab.*</FILTER>
40
+    </SUITE>
25 41
   </component>
26 42
   <component name="FileEditorManager">
27 43
     <splitter split-orientation="horizontal" split-proportion="0.5">
28 44
       <split-first>
29 45
         <leaf>
30
-          <file leaf-file-name="CheckingAccount.java" pinned="false" current-in-tab="true">
31
-            <entry file="file://$PROJECT_DIR$/src/main/java/com/zipcodewilmington/bankaccountlab/CheckingAccount.java">
46
+          <file leaf-file-name="AccountFactory.java" pinned="false" current-in-tab="true">
47
+            <entry file="file://$PROJECT_DIR$/src/main/java/com/zipcodewilmington/bankaccountlab/AccountFactory.java">
32 48
               <provider selected="true" editor-type-id="text-editor">
33
-                <state relative-caret-position="176">
34
-                  <caret line="11" column="18" lean-forward="false" selection-start-line="11" selection-start-column="18" selection-end-line="11" selection-end-column="18" />
35
-                  <folding>
36
-                    <element signature="e#134#135#0" expanded="true" />
37
-                    <element signature="e#164#165#0" expanded="true" />
38
-                  </folding>
49
+                <state relative-caret-position="128">
50
+                  <caret line="8" column="68" lean-forward="true" selection-start-line="8" selection-start-column="68" selection-end-line="8" selection-end-column="68" />
51
+                  <folding />
39 52
                 </state>
40 53
               </provider>
41 54
             </entry>
@@ -44,11 +57,11 @@
44 57
       </split-first>
45 58
       <split-second>
46 59
         <leaf>
47
-          <file leaf-file-name="Account.java" pinned="false" current-in-tab="true">
48
-            <entry file="file://$PROJECT_DIR$/src/main/java/com/zipcodewilmington/bankaccountlab/Account.java">
60
+          <file leaf-file-name="MainApplication.java" pinned="false" current-in-tab="true">
61
+            <entry file="file://$PROJECT_DIR$/src/main/java/com/zipcodewilmington/bankaccountlab/MainApplication.java">
49 62
               <provider selected="true" editor-type-id="text-editor">
50
-                <state relative-caret-position="272">
51
-                  <caret line="19" column="13" lean-forward="true" selection-start-line="19" selection-start-column="13" selection-end-line="19" selection-end-column="13" />
63
+                <state relative-caret-position="80">
64
+                  <caret line="5" column="13" lean-forward="false" selection-start-line="5" selection-start-column="13" selection-end-line="5" selection-end-column="13" />
52 65
                   <folding />
53 66
                 </state>
54 67
               </provider>
@@ -61,11 +74,16 @@
61 74
   <component name="FileTemplateManagerImpl">
62 75
     <option name="RECENT_TEMPLATES">
63 76
       <list>
64
-        <option value="Class" />
65 77
         <option value="JUnit4 Test Class" />
78
+        <option value="Class" />
66 79
       </list>
67 80
     </option>
68 81
   </component>
82
+  <component name="FindInProjectRecents">
83
+    <replaceStrings>
84
+      <replace />
85
+    </replaceStrings>
86
+  </component>
69 87
   <component name="Git.Settings">
70 88
     <option name="RECENT_GIT_ROOT_PATH" value="$PROJECT_DIR$" />
71 89
   </component>
@@ -79,12 +97,21 @@
79 97
       <list>
80 98
         <option value="$PROJECT_DIR$/pom.xml" />
81 99
         <option value="$PROJECT_DIR$/src/test/java/com/zipcodewilmington/bankaccountlab/MainApplicationTest.java" />
82
-        <option value="$PROJECT_DIR$/src/test/java/com/zipcodewilmington/bankaccountlab/AccountTest.java" />
83 100
         <option value="$PROJECT_DIR$/src/main/java/com/zipcodewilmington/bankaccountlab/SavingsAccount.java" />
84 101
         <option value="$PROJECT_DIR$/src/test/java/com/zipcodewilmington/bankaccountlab/SavingsAccountTest.java" />
85
-        <option value="$PROJECT_DIR$/src/main/java/com/zipcodewilmington/bankaccountlab/Account.java" />
86 102
         <option value="$PROJECT_DIR$/src/main/java/com/zipcodewilmington/bankaccountlab/CheckingAccount.java" />
87 103
         <option value="$PROJECT_DIR$/src/test/java/com/zipcodewilmington/bankaccountlab/CheckingAccountTest.java" />
104
+        <option value="$PROJECT_DIR$/src/main/java/com/zipcodewilmington/bankaccountlab/Account.java" />
105
+        <option value="$PROJECT_DIR$/src/test/java/com/zipcodewilmington/bankaccountlab/AccountTest.java" />
106
+        <option value="$PROJECT_DIR$/src/test/java/com/zipcodewilmington/bankaccountlab/BankAccountFactoryTest.java" />
107
+        <option value="$PROJECT_DIR$/src/test/java/com/zipcodewilmington/bankaccountlab/BuisnessAccountTest.java" />
108
+        <option value="$PROJECT_DIR$/src/main/java/com/zipcodewilmington/bankaccountlab/BuisnessAccount.java" />
109
+        <option value="$PROJECT_DIR$/src/main/java/com/zipcodewilmington/bankaccountlab/BusinessAccount.java" />
110
+        <option value="$PROJECT_DIR$/src/test/java/com/zipcodewilmington/bankaccountlab/BusinessAccountTest.java" />
111
+        <option value="$PROJECT_DIR$/src/main/java/com/zipcodewilmington/bankaccountlab/BankAccountFactory.java" />
112
+        <option value="$PROJECT_DIR$/src/main/java/com/zipcodewilmington/bankaccountlab/AccountType.java" />
113
+        <option value="$PROJECT_DIR$/src/main/java/com/zipcodewilmington/bankaccountlab/AccountFactory.java" />
114
+        <option value="$PROJECT_DIR$/src/test/java/com/zipcodewilmington/bankaccountlab/AccountFactoryTest.java" />
88 115
       </list>
89 116
     </option>
90 117
   </component>
@@ -200,7 +227,10 @@
200 227
     <property name="WebServerToolWindowFactoryState" value="false" />
201 228
     <property name="aspect.path.notification.shown" value="true" />
202 229
     <property name="com.intellij.testIntegration.createTest.CreateTestDialog.defaultLibrary" value="JUnit4" />
203
-    <property name="settings.editor.selected.configurable" value="keyPromoterConfiguration" />
230
+    <property name="settings.editor.selected.configurable" value="preferences.keymap" />
231
+    <property name="project.structure.last.edited" value="Project" />
232
+    <property name="project.structure.proportion" value="0.15" />
233
+    <property name="project.structure.side.proportion" value="0.2" />
204 234
   </component>
205 235
   <component name="RecentsManager">
206 236
     <key name="CreateTestDialog.RecentsKey">
@@ -222,7 +252,7 @@
222 252
       </list>
223 253
     </option>
224 254
   </component>
225
-  <component name="RunManager" selected="JUnit.CheckingAccountTest">
255
+  <component name="RunManager" selected="JUnit.com.zipcodewilmington.bankaccountlab in bankaccountlab">
226 256
     <configuration default="true" type="Applet" factoryName="Applet">
227 257
       <option name="HTML_USED" value="false" />
228 258
       <option name="WIDTH" value="400" />
@@ -244,7 +274,7 @@
244 274
       <module name="" />
245 275
       <envs />
246 276
     </configuration>
247
-    <configuration name="CheckingAccountTest" type="JUnit" factoryName="JUnit" temporary="true" nameIsGenerated="true">
277
+    <configuration name="AccountFactoryTest" type="JUnit" factoryName="JUnit" temporary="true" nameIsGenerated="true">
248 278
       <extension name="coverage" enabled="false" merge="false" sample_coverage="true" runner="idea">
249 279
         <pattern>
250 280
           <option name="PATTERN" value="com.zipcodewilmington.bankaccountlab.*" />
@@ -255,7 +285,7 @@
255 285
       <option name="ALTERNATIVE_JRE_PATH_ENABLED" value="false" />
256 286
       <option name="ALTERNATIVE_JRE_PATH" />
257 287
       <option name="PACKAGE_NAME" value="com.zipcodewilmington.bankaccountlab" />
258
-      <option name="MAIN_CLASS_NAME" value="com.zipcodewilmington.bankaccountlab.CheckingAccountTest" />
288
+      <option name="MAIN_CLASS_NAME" value="com.zipcodewilmington.bankaccountlab.AccountFactoryTest" />
259 289
       <option name="METHOD_NAME" />
260 290
       <option name="TEST_OBJECT" value="class" />
261 291
       <option name="VM_PARAMETERS" value="-ea" />
@@ -269,7 +299,7 @@
269 299
       <envs />
270 300
       <patterns />
271 301
     </configuration>
272
-    <configuration name="CheckingAccountTest.constructorTest" type="JUnit" factoryName="JUnit" temporary="true" nameIsGenerated="true">
302
+    <configuration name="AccountFactoryTest.getBuisnessAccount" type="JUnit" factoryName="JUnit" temporary="true" nameIsGenerated="true">
273 303
       <extension name="coverage" enabled="false" merge="false" sample_coverage="true" runner="idea">
274 304
         <pattern>
275 305
           <option name="PATTERN" value="com.zipcodewilmington.bankaccountlab.*" />
@@ -280,8 +310,8 @@
280 310
       <option name="ALTERNATIVE_JRE_PATH_ENABLED" value="false" />
281 311
       <option name="ALTERNATIVE_JRE_PATH" />
282 312
       <option name="PACKAGE_NAME" value="com.zipcodewilmington.bankaccountlab" />
283
-      <option name="MAIN_CLASS_NAME" value="com.zipcodewilmington.bankaccountlab.CheckingAccountTest" />
284
-      <option name="METHOD_NAME" value="constructorTest" />
313
+      <option name="MAIN_CLASS_NAME" value="com.zipcodewilmington.bankaccountlab.AccountFactoryTest" />
314
+      <option name="METHOD_NAME" value="getBuisnessAccount" />
285 315
       <option name="TEST_OBJECT" value="method" />
286 316
       <option name="VM_PARAMETERS" value="-ea" />
287 317
       <option name="PARAMETERS" />
@@ -294,7 +324,7 @@
294 324
       <envs />
295 325
       <patterns />
296 326
     </configuration>
297
-    <configuration name="CheckingAccountTest.withdrawBalance" type="JUnit" factoryName="JUnit" temporary="true" nameIsGenerated="true">
327
+    <configuration name="BusinessAccountTest" type="JUnit" factoryName="JUnit" temporary="true" nameIsGenerated="true">
298 328
       <extension name="coverage" enabled="false" merge="false" sample_coverage="true" runner="idea">
299 329
         <pattern>
300 330
           <option name="PATTERN" value="com.zipcodewilmington.bankaccountlab.*" />
@@ -305,9 +335,9 @@
305 335
       <option name="ALTERNATIVE_JRE_PATH_ENABLED" value="false" />
306 336
       <option name="ALTERNATIVE_JRE_PATH" />
307 337
       <option name="PACKAGE_NAME" value="com.zipcodewilmington.bankaccountlab" />
308
-      <option name="MAIN_CLASS_NAME" value="com.zipcodewilmington.bankaccountlab.CheckingAccountTest" />
309
-      <option name="METHOD_NAME" value="withdrawBalance" />
310
-      <option name="TEST_OBJECT" value="method" />
338
+      <option name="MAIN_CLASS_NAME" value="com.zipcodewilmington.bankaccountlab.BusinessAccountTest" />
339
+      <option name="METHOD_NAME" />
340
+      <option name="TEST_OBJECT" value="class" />
311 341
       <option name="VM_PARAMETERS" value="-ea" />
312 342
       <option name="PARAMETERS" />
313 343
       <option name="WORKING_DIRECTORY" value="%MODULE_WORKING_DIR%" />
@@ -319,7 +349,7 @@
319 349
       <envs />
320 350
       <patterns />
321 351
     </configuration>
322
-    <configuration name="CheckingAccountTest.withdrawBalanceSuccessTest" type="JUnit" factoryName="JUnit" temporary="true" nameIsGenerated="true">
352
+    <configuration name="BusinessAccountTest.depositMoneyTest" type="JUnit" factoryName="JUnit" temporary="true" nameIsGenerated="true">
323 353
       <extension name="coverage" enabled="false" merge="false" sample_coverage="true" runner="idea">
324 354
         <pattern>
325 355
           <option name="PATTERN" value="com.zipcodewilmington.bankaccountlab.*" />
@@ -330,8 +360,8 @@
330 360
       <option name="ALTERNATIVE_JRE_PATH_ENABLED" value="false" />
331 361
       <option name="ALTERNATIVE_JRE_PATH" />
332 362
       <option name="PACKAGE_NAME" value="com.zipcodewilmington.bankaccountlab" />
333
-      <option name="MAIN_CLASS_NAME" value="com.zipcodewilmington.bankaccountlab.CheckingAccountTest" />
334
-      <option name="METHOD_NAME" value="withdrawBalanceSuccessTest" />
363
+      <option name="MAIN_CLASS_NAME" value="com.zipcodewilmington.bankaccountlab.BusinessAccountTest" />
364
+      <option name="METHOD_NAME" value="depositMoneyTest" />
335 365
       <option name="TEST_OBJECT" value="method" />
336 366
       <option name="VM_PARAMETERS" value="-ea" />
337 367
       <option name="PARAMETERS" />
@@ -344,20 +374,15 @@
344 374
       <envs />
345 375
       <patterns />
346 376
     </configuration>
347
-    <configuration name="SavingsAccountTest.withdrawBalanceFalseByTooMuchWithdrawals" type="JUnit" factoryName="JUnit" temporary="true" nameIsGenerated="true">
348
-      <extension name="coverage" enabled="false" merge="false" sample_coverage="true" runner="idea">
349
-        <pattern>
350
-          <option name="PATTERN" value="com.zipcodewilmington.bankaccountlab.*" />
351
-          <option name="ENABLED" value="true" />
352
-        </pattern>
353
-      </extension>
354
-      <module name="bankaccountlab" />
377
+    <configuration default="true" type="JUnit" factoryName="JUnit">
378
+      <extension name="coverage" enabled="false" merge="false" sample_coverage="true" runner="idea" />
379
+      <module name="" />
355 380
       <option name="ALTERNATIVE_JRE_PATH_ENABLED" value="false" />
356 381
       <option name="ALTERNATIVE_JRE_PATH" />
357
-      <option name="PACKAGE_NAME" value="com.zipcodewilmington.bankaccountlab" />
358
-      <option name="MAIN_CLASS_NAME" value="com.zipcodewilmington.bankaccountlab.SavingsAccountTest" />
359
-      <option name="METHOD_NAME" value="withdrawBalanceFalseByTooMuchWithdrawals" />
360
-      <option name="TEST_OBJECT" value="method" />
382
+      <option name="PACKAGE_NAME" />
383
+      <option name="MAIN_CLASS_NAME" />
384
+      <option name="METHOD_NAME" />
385
+      <option name="TEST_OBJECT" value="class" />
361 386
       <option name="VM_PARAMETERS" value="-ea" />
362 387
       <option name="PARAMETERS" />
363 388
       <option name="WORKING_DIRECTORY" value="%MODULE_WORKING_DIR%" />
@@ -369,15 +394,20 @@
369 394
       <envs />
370 395
       <patterns />
371 396
     </configuration>
372
-    <configuration default="true" type="JUnit" factoryName="JUnit">
373
-      <extension name="coverage" enabled="false" merge="false" sample_coverage="true" runner="idea" />
374
-      <module name="" />
397
+    <configuration name="com.zipcodewilmington.bankaccountlab in bankaccountlab" type="JUnit" factoryName="JUnit" temporary="true" nameIsGenerated="true">
398
+      <extension name="coverage" enabled="false" merge="false" sample_coverage="true" runner="idea">
399
+        <pattern>
400
+          <option name="PATTERN" value="com.zipcodewilmington.bankaccountlab.*" />
401
+          <option name="ENABLED" value="true" />
402
+        </pattern>
403
+      </extension>
404
+      <module name="bankaccountlab" />
375 405
       <option name="ALTERNATIVE_JRE_PATH_ENABLED" value="false" />
376 406
       <option name="ALTERNATIVE_JRE_PATH" />
377
-      <option name="PACKAGE_NAME" />
407
+      <option name="PACKAGE_NAME" value="com.zipcodewilmington.bankaccountlab" />
378 408
       <option name="MAIN_CLASS_NAME" />
379 409
       <option name="METHOD_NAME" />
380
-      <option name="TEST_OBJECT" value="class" />
410
+      <option name="TEST_OBJECT" value="package" />
381 411
       <option name="VM_PARAMETERS" value="-ea" />
382 412
       <option name="PARAMETERS" />
383 413
       <option name="WORKING_DIRECTORY" value="%MODULE_WORKING_DIR%" />
@@ -430,19 +460,19 @@
430 460
       <predefined_log_file id="idea.log" enabled="true" />
431 461
     </configuration>
432 462
     <list size="5">
433
-      <item index="0" class="java.lang.String" itemvalue="JUnit.SavingsAccountTest.withdrawBalanceFalseByTooMuchWithdrawals" />
434
-      <item index="1" class="java.lang.String" itemvalue="JUnit.CheckingAccountTest.constructorTest" />
435
-      <item index="2" class="java.lang.String" itemvalue="JUnit.CheckingAccountTest.withdrawBalance" />
436
-      <item index="3" class="java.lang.String" itemvalue="JUnit.CheckingAccountTest.withdrawBalanceSuccessTest" />
437
-      <item index="4" class="java.lang.String" itemvalue="JUnit.CheckingAccountTest" />
463
+      <item index="0" class="java.lang.String" itemvalue="JUnit.com.zipcodewilmington.bankaccountlab in bankaccountlab" />
464
+      <item index="1" class="java.lang.String" itemvalue="JUnit.BusinessAccountTest" />
465
+      <item index="2" class="java.lang.String" itemvalue="JUnit.BusinessAccountTest.depositMoneyTest" />
466
+      <item index="3" class="java.lang.String" itemvalue="JUnit.AccountFactoryTest.getBuisnessAccount" />
467
+      <item index="4" class="java.lang.String" itemvalue="JUnit.AccountFactoryTest" />
438 468
     </list>
439 469
     <recent_temporary>
440 470
       <list size="5">
441
-        <item index="0" class="java.lang.String" itemvalue="JUnit.CheckingAccountTest" />
442
-        <item index="1" class="java.lang.String" itemvalue="JUnit.CheckingAccountTest.withdrawBalanceSuccessTest" />
443
-        <item index="2" class="java.lang.String" itemvalue="JUnit.CheckingAccountTest.withdrawBalance" />
444
-        <item index="3" class="java.lang.String" itemvalue="JUnit.CheckingAccountTest.constructorTest" />
445
-        <item index="4" class="java.lang.String" itemvalue="JUnit.SavingsAccountTest.withdrawBalanceFalseByTooMuchWithdrawals" />
471
+        <item index="0" class="java.lang.String" itemvalue="JUnit.com.zipcodewilmington.bankaccountlab in bankaccountlab" />
472
+        <item index="1" class="java.lang.String" itemvalue="JUnit.AccountFactoryTest" />
473
+        <item index="2" class="java.lang.String" itemvalue="JUnit.AccountFactoryTest.getBuisnessAccount" />
474
+        <item index="3" class="java.lang.String" itemvalue="JUnit.BusinessAccountTest.depositMoneyTest" />
475
+        <item index="4" class="java.lang.String" itemvalue="JUnit.BusinessAccountTest" />
446 476
       </list>
447 477
     </recent_temporary>
448 478
   </component>
@@ -463,48 +493,47 @@
463 493
       <workItem from="1528826249055" duration="238000" />
464 494
       <workItem from="1528826547433" duration="435000" />
465 495
       <workItem from="1528827032542" duration="1168000" />
466
-      <workItem from="1529015302668" duration="1443000" />
496
+      <workItem from="1529015302668" duration="8636000" />
467 497
     </task>
468 498
     <servers />
469 499
   </component>
470 500
   <component name="TestHistory">
471
-    <history-entry file="CheckingAccountTest - 2018.06.14 at 19h 09m 59s.xml">
472
-      <configuration name="CheckingAccountTest" configurationId="JUnit" />
501
+    <history-entry file="AccountFactoryTest - 2018.06.15 at 10h 48m 36s.xml">
502
+      <configuration name="AccountFactoryTest" configurationId="JUnit" />
473 503
     </history-entry>
474
-    <history-entry file="CheckingAccountTest - 2018.06.14 at 19h 10m 18s.xml">
475
-      <configuration name="CheckingAccountTest" configurationId="JUnit" />
504
+    <history-entry file="AccountFactoryTest_getBuisnessAccount - 2018.06.15 at 10h 46m 41s.xml">
505
+      <configuration name="AccountFactoryTest.getBuisnessAccount" configurationId="JUnit" />
476 506
     </history-entry>
477
-    <history-entry file="CheckingAccountTest - 2018.06.14 at 19h 10m 45s.xml">
478
-      <configuration name="CheckingAccountTest" configurationId="JUnit" />
507
+    <history-entry file="AccountFactoryTest_getBuisnessAccount - 2018.06.15 at 10h 47m 02s.xml">
508
+      <configuration name="AccountFactoryTest.getBuisnessAccount" configurationId="JUnit" />
479 509
     </history-entry>
480
-    <history-entry file="CheckingAccountTest - 2018.06.14 at 19h 11m 06s.xml">
481
-      <configuration name="CheckingAccountTest" configurationId="JUnit" />
510
+    <history-entry file="BusinessAccountTest_depositMoneyTest - 2018.06.15 at 09h 00m 09s.xml">
511
+      <configuration name="BusinessAccountTest.depositMoneyTest" configurationId="JUnit" />
482 512
     </history-entry>
483
-    <history-entry file="CheckingAccountTest_constructorTest - 2018.06.14 at 18h 39m 05s.xml">
484
-      <configuration name="CheckingAccountTest.constructorTest" configurationId="JUnit" />
513
+    <history-entry file="BusinessAccountTest_depositMoneyTest - 2018.06.15 at 09h 01m 16s.xml">
514
+      <configuration name="BusinessAccountTest.depositMoneyTest" configurationId="JUnit" />
485 515
     </history-entry>
486
-    <history-entry file="CheckingAccountTest_withdrawBalance - 2018.06.14 at 18h 41m 01s.xml">
487
-      <configuration name="CheckingAccountTest.withdrawBalance" configurationId="JUnit" />
516
+    <history-entry file="BusinessAccountTest_depositMoneyTest - 2018.06.15 at 09h 01m 20s.xml">
517
+      <configuration name="BusinessAccountTest.depositMoneyTest" configurationId="JUnit" />
488 518
     </history-entry>
489
-    <history-entry file="CheckingAccountTest_withdrawBalanceSuccessTest - 2018.06.14 at 19h 09m 20s.xml">
490
-      <configuration name="CheckingAccountTest.withdrawBalanceSuccessTest" configurationId="JUnit" />
519
+    <history-entry file="BusinessAccountTest_depositMoneyTest - 2018.06.15 at 09h 01m 27s.xml">
520
+      <configuration name="BusinessAccountTest.depositMoneyTest" configurationId="JUnit" />
491 521
     </history-entry>
492
-    <history-entry file="CheckingAccountTest_withdrawBalanceSuccessTest - 2018.06.14 at 19h 09m 52s.xml">
493
-      <configuration name="CheckingAccountTest.withdrawBalanceSuccessTest" configurationId="JUnit" />
522
+    <history-entry file="com_zipcodewilmington_bankaccountlab_in_bankaccountlab - 2018.06.15 at 09h 02m 18s.xml">
523
+      <configuration name="com.zipcodewilmington.bankaccountlab in bankaccountlab" configurationId="JUnit" />
494 524
     </history-entry>
495
-    <history-entry file="SavingsAccountTest_withdrawBalanceFalseByTooMuchWithdrawals - 2018.06.14 at 18h 31m 52s.xml">
496
-      <configuration name="SavingsAccountTest.withdrawBalanceFalseByTooMuchWithdrawals" configurationId="JUnit" />
525
+    <history-entry file="com_zipcodewilmington_bankaccountlab_in_bankaccountlab - 2018.06.15 at 10h 43m 01s.xml">
526
+      <configuration name="com.zipcodewilmington.bankaccountlab in bankaccountlab" configurationId="JUnit" />
497 527
     </history-entry>
498
-    <history-entry file="SavingsAccountTest_withdrawBalanceFalseByTooMuchWithdrawals - 2018.06.14 at 18h 32m 12s.xml">
499
-      <configuration name="SavingsAccountTest.withdrawBalanceFalseByTooMuchWithdrawals" configurationId="JUnit" />
528
+    <history-entry file="com_zipcodewilmington_bankaccountlab_in_bankaccountlab - 2018.06.15 at 11h 39m 54s.xml">
529
+      <configuration name="com.zipcodewilmington.bankaccountlab in bankaccountlab" configurationId="JUnit" />
500 530
     </history-entry>
501 531
   </component>
502 532
   <component name="TimeTrackingManager">
503
-    <option name="totallyTimeSpent" value="7856000" />
533
+    <option name="totallyTimeSpent" value="15049000" />
504 534
   </component>
505 535
   <component name="ToolWindowManager">
506 536
     <frame x="4" y="4" width="1272" height="792" extended-state="6" />
507
-    <editor active="true" />
508 537
     <layout>
509 538
       <window_info id="Key Promoter X" active="false" anchor="right" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.33" sideWeight="0.5" order="3" side_tool="false" content_ui="tabs" />
510 539
       <window_info id="Palette" active="false" anchor="right" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.33" sideWeight="0.5" order="3" side_tool="false" content_ui="tabs" />
@@ -517,12 +546,13 @@
517 546
       <window_info id="Maven Projects" active="false" anchor="right" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.32996634" sideWeight="0.5" order="3" side_tool="false" content_ui="tabs" />
518 547
       <window_info id="Run" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="true" show_stripe_button="true" weight="0.32998565" sideWeight="0.5" order="2" side_tool="false" content_ui="tabs" />
519 548
       <window_info id="Version Control" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.33" sideWeight="0.5" order="7" side_tool="false" content_ui="tabs" />
520
-      <window_info id="Coverage" active="false" anchor="right" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="true" show_stripe_button="true" weight="0.3292683" sideWeight="0.5" order="4" side_tool="true" content_ui="tabs" />
549
+      <window_info id="Coverage" active="true" anchor="right" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="true" show_stripe_button="true" weight="0.32764226" sideWeight="0.5" order="4" side_tool="true" content_ui="tabs" />
521 550
       <window_info id="Terminal" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.33" sideWeight="0.5" order="7" side_tool="false" content_ui="tabs" />
522 551
       <window_info id="Capture Tool" active="false" anchor="left" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.33" sideWeight="0.5" order="2" side_tool="false" content_ui="tabs" />
523 552
       <window_info id="Designer" active="false" anchor="left" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.33" sideWeight="0.5" order="2" side_tool="false" content_ui="tabs" />
524
-      <window_info id="Project" active="false" anchor="left" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="true" show_stripe_button="true" weight="0.121138215" sideWeight="0.5" order="0" side_tool="false" content_ui="combo" />
553
+      <window_info id="Project" active="false" anchor="left" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="true" show_stripe_button="true" weight="0.3699187" sideWeight="0.5" order="0" side_tool="false" content_ui="combo" />
525 554
       <window_info id="Database" active="false" anchor="right" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.33" sideWeight="0.5" order="3" side_tool="false" content_ui="tabs" />
555
+      <window_info id="Find" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.33" sideWeight="0.5" order="1" side_tool="false" content_ui="tabs" />
526 556
       <window_info id="Structure" active="false" anchor="left" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.25" sideWeight="0.5" order="1" side_tool="false" content_ui="tabs" />
527 557
       <window_info id="Ant Build" active="false" anchor="right" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.25" sideWeight="0.5" order="1" side_tool="false" content_ui="tabs" />
528 558
       <window_info id="UI Designer" active="false" anchor="left" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.33" sideWeight="0.5" order="2" side_tool="false" content_ui="tabs" />
@@ -534,7 +564,6 @@
534 564
       <window_info id="Commander" active="false" anchor="right" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.4" sideWeight="0.5" order="0" side_tool="false" content_ui="tabs" />
535 565
       <window_info id="Hierarchy" active="false" anchor="right" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.25" sideWeight="0.5" order="2" side_tool="false" content_ui="combo" />
536 566
       <window_info id="Inspection" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.4" sideWeight="0.5" order="5" side_tool="false" content_ui="tabs" />
537
-      <window_info id="Find" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.33" sideWeight="0.5" order="1" side_tool="false" content_ui="tabs" />
538 567
     </layout>
539 568
   </component>
540 569
   <component name="TypeScriptGeneratedFilesManager">
@@ -545,7 +574,7 @@
545 574
   </component>
546 575
   <component name="XDebuggerManager">
547 576
     <breakpoint-manager>
548
-      <option name="time" value="1" />
577
+      <option name="time" value="3" />
549 578
     </breakpoint-manager>
550 579
     <watches-manager />
551 580
   </component>
@@ -563,9 +592,9 @@
563 592
         <state relative-caret-position="272">
564 593
           <caret line="22" column="21" lean-forward="false" selection-start-line="22" selection-start-column="21" selection-end-line="22" selection-end-column="21" />
565 594
           <folding>
566
-            <element signature="imports" expanded="true" />
567
-            <element signature="e#233#234#0" expanded="true" />
568
-            <element signature="e#278#279#0" expanded="true" />
595
+            <element signature="imports" expanded="false" />
596
+            <element signature="e#233#234#0" expanded="false" />
597
+            <element signature="e#278#279#0" expanded="false" />
569 598
           </folding>
570 599
         </state>
571 600
       </provider>
@@ -583,9 +612,9 @@
583 612
         <state relative-caret-position="224">
584 613
           <caret line="14" column="0" lean-forward="false" selection-start-line="14" selection-start-column="0" selection-end-line="14" selection-end-column="0" />
585 614
           <folding>
586
-            <element signature="imports" expanded="true" />
587
-            <element signature="e#233#234#0" expanded="true" />
588
-            <element signature="e#278#279#0" expanded="true" />
615
+            <element signature="imports" expanded="false" />
616
+            <element signature="e#233#234#0" expanded="false" />
617
+            <element signature="e#278#279#0" expanded="false" />
589 618
           </folding>
590 619
         </state>
591 620
       </provider>
@@ -603,9 +632,9 @@
603 632
         <state relative-caret-position="80">
604 633
           <caret line="7" column="7" lean-forward="false" selection-start-line="7" selection-start-column="7" selection-end-line="7" selection-end-column="7" />
605 634
           <folding>
606
-            <element signature="imports" expanded="true" />
607
-            <element signature="e#233#234#0" expanded="true" />
608
-            <element signature="e#278#279#0" expanded="true" />
635
+            <element signature="imports" expanded="false" />
636
+            <element signature="e#233#234#0" expanded="false" />
637
+            <element signature="e#278#279#0" expanded="false" />
609 638
           </folding>
610 639
         </state>
611 640
       </provider>
@@ -626,27 +655,6 @@
626 655
         </state>
627 656
       </provider>
628 657
     </entry>
629
-    <entry file="file://$PROJECT_DIR$/src/test/java/com/zipcodewilmington/bankaccountlab/BankAccountTest.java">
630
-      <provider selected="true" editor-type-id="text-editor">
631
-        <state relative-caret-position="80">
632
-          <caret line="5" column="29" lean-forward="false" selection-start-line="5" selection-start-column="29" selection-end-line="5" selection-end-column="29" />
633
-        </state>
634
-      </provider>
635
-    </entry>
636
-    <entry file="file://$PROJECT_DIR$/src/main/java/com/zipcodewilmington/bankaccountlab/BankAccount.java">
637
-      <provider selected="true" editor-type-id="text-editor">
638
-        <state relative-caret-position="80">
639
-          <caret line="5" column="14" lean-forward="false" selection-start-line="5" selection-start-column="14" selection-end-line="5" selection-end-column="14" />
640
-        </state>
641
-      </provider>
642
-    </entry>
643
-    <entry file="file://$PROJECT_DIR$/src/main/java/com/zipcodewilmington/bankaccountlab/BuisnessAccount.java">
644
-      <provider selected="true" editor-type-id="text-editor">
645
-        <state relative-caret-position="32">
646
-          <caret line="2" column="28" lean-forward="false" selection-start-line="2" selection-start-column="28" selection-end-line="2" selection-end-column="28" />
647
-        </state>
648
-      </provider>
649
-    </entry>
650 658
     <entry file="file://$PROJECT_DIR$/src/test/java/com/zipcodewilmington/bankaccountlab/MainApplicationTest.java">
651 659
       <provider selected="true" editor-type-id="text-editor">
652 660
         <state relative-caret-position="64">
@@ -655,24 +663,38 @@
655 663
         </state>
656 664
       </provider>
657 665
     </entry>
666
+    <entry file="file://$PROJECT_DIR$/src/test/java/com/zipcodewilmington/bankaccountlab/CheckingAccountTest.java">
667
+      <provider selected="true" editor-type-id="text-editor">
668
+        <state relative-caret-position="448">
669
+          <caret line="28" column="47" lean-forward="false" selection-start-line="28" selection-start-column="47" selection-end-line="28" selection-end-column="47" />
670
+          <folding>
671
+            <element signature="imports" expanded="false" />
672
+            <element signature="e#235#236#0" expanded="false" />
673
+            <element signature="e#281#282#0" expanded="false" />
674
+            <element signature="e#328#329#0" expanded="false" />
675
+            <element signature="e#394#395#0" expanded="false" />
676
+          </folding>
677
+        </state>
678
+      </provider>
679
+    </entry>
658 680
     <entry file="file://$PROJECT_DIR$/src/test/java/com/zipcodewilmington/bankaccountlab/AccountTest.java">
659 681
       <provider selected="true" editor-type-id="text-editor">
660
-        <state relative-caret-position="112">
661
-          <caret line="10" column="4" lean-forward="false" selection-start-line="10" selection-start-column="4" selection-end-line="10" selection-end-column="4" />
682
+        <state relative-caret-position="322">
683
+          <caret line="43" column="26" lean-forward="false" selection-start-line="43" selection-start-column="26" selection-end-line="43" selection-end-column="26" />
662 684
           <folding>
663
-            <element signature="imports" expanded="true" />
664
-            <element signature="e#246#247#0" expanded="true" />
665
-            <element signature="e#284#285#0" expanded="true" />
666
-            <element signature="e#367#368#0" expanded="true" />
667
-            <element signature="e#403#404#0" expanded="true" />
685
+            <element signature="imports" expanded="false" />
686
+            <element signature="e#246#247#0" expanded="false" />
687
+            <element signature="e#284#285#0" expanded="false" />
688
+            <element signature="e#367#368#0" expanded="false" />
689
+            <element signature="e#403#404#0" expanded="false" />
668 690
           </folding>
669 691
         </state>
670 692
       </provider>
671 693
     </entry>
672
-    <entry file="file://$PROJECT_DIR$/src/main/java/com/zipcodewilmington/bankaccountlab/MainApplication.java">
694
+    <entry file="file://$PROJECT_DIR$/src/test/java/com/zipcodewilmington/bankaccountlab/BankAccountTest.java">
673 695
       <provider selected="true" editor-type-id="text-editor">
674
-        <state relative-caret-position="80">
675
-          <caret line="5" column="13" lean-forward="false" selection-start-line="5" selection-start-column="13" selection-end-line="5" selection-end-column="13" />
696
+        <state relative-caret-position="96">
697
+          <caret line="6" column="0" lean-forward="false" selection-start-line="6" selection-start-column="0" selection-end-line="6" selection-end-column="0" />
676 698
           <folding />
677 699
         </state>
678 700
       </provider>
@@ -687,45 +709,94 @@
687 709
     </entry>
688 710
     <entry file="file://$PROJECT_DIR$/src/main/java/com/zipcodewilmington/bankaccountlab/CheckingAccount.java">
689 711
       <provider selected="true" editor-type-id="text-editor">
712
+        <state relative-caret-position="192">
713
+          <caret line="14" column="4" lean-forward="false" selection-start-line="14" selection-start-column="4" selection-end-line="14" selection-end-column="4" />
714
+          <folding />
715
+        </state>
716
+      </provider>
717
+    </entry>
718
+    <entry file="file://$PROJECT_DIR$/src/test/java/com/zipcodewilmington/bankaccountlab/BusinessAccountTest.java">
719
+      <provider selected="true" editor-type-id="text-editor">
690 720
         <state relative-caret-position="176">
691
-          <caret line="11" column="18" lean-forward="false" selection-start-line="11" selection-start-column="18" selection-end-line="11" selection-end-column="18" />
721
+          <caret line="21" column="20" lean-forward="false" selection-start-line="21" selection-start-column="20" selection-end-line="21" selection-end-column="20" />
692 722
           <folding>
693
-            <element signature="e#134#135#0" expanded="true" />
694
-            <element signature="e#164#165#0" expanded="true" />
723
+            <element signature="imports" expanded="false" />
724
+            <element signature="e#235#236#0" expanded="false" />
725
+            <element signature="e#283#284#0" expanded="false" />
726
+            <element signature="e#330#331#0" expanded="false" />
727
+            <element signature="e#396#397#0" expanded="false" />
728
+            <element signature="e#453#454#0" expanded="false" />
729
+            <element signature="e#504#505#0" expanded="false" />
730
+            <element signature="e#561#562#0" expanded="false" />
731
+            <element signature="e#617#618#0" expanded="false" />
732
+          </folding>
733
+        </state>
734
+      </provider>
735
+    </entry>
736
+    <entry file="file://$PROJECT_DIR$/src/main/java/com/zipcodewilmington/bankaccountlab/BusinessAccount.java">
737
+      <provider selected="true" editor-type-id="text-editor">
738
+        <state relative-caret-position="256">
739
+          <caret line="16" column="0" lean-forward="true" selection-start-line="16" selection-start-column="0" selection-end-line="16" selection-end-column="0" />
740
+          <folding>
741
+            <element signature="e#133#134#0" expanded="true" />
742
+            <element signature="e#166#167#0" expanded="true" />
695 743
           </folding>
696 744
         </state>
697 745
       </provider>
698 746
     </entry>
699 747
     <entry file="file://$PROJECT_DIR$/src/test/java/com/zipcodewilmington/bankaccountlab/SavingsAccountTest.java">
700 748
       <provider selected="true" editor-type-id="text-editor">
701
-        <state relative-caret-position="96">
702
-          <caret line="6" column="0" lean-forward="true" selection-start-line="6" selection-start-column="0" selection-end-line="6" selection-end-column="0" />
749
+        <state relative-caret-position="64">
750
+          <caret line="7" column="13" lean-forward="false" selection-start-line="7" selection-start-column="13" selection-end-line="7" selection-end-column="13" />
751
+          <folding />
752
+        </state>
753
+      </provider>
754
+    </entry>
755
+    <entry file="file://$PROJECT_DIR$/src/main/java/com/zipcodewilmington/bankaccountlab/Account.java">
756
+      <provider selected="true" editor-type-id="text-editor">
757
+        <state relative-caret-position="160">
758
+          <caret line="12" column="4" lean-forward="false" selection-start-line="12" selection-start-column="4" selection-end-line="12" selection-end-column="4" />
759
+          <folding />
760
+        </state>
761
+      </provider>
762
+    </entry>
763
+    <entry file="file://$PROJECT_DIR$/src/test/java/com/zipcodewilmington/bankaccountlab/AccountFactoryTest.java">
764
+      <provider selected="true" editor-type-id="text-editor">
765
+        <state relative-caret-position="272">
766
+          <caret line="17" column="0" lean-forward="false" selection-start-line="17" selection-start-column="0" selection-end-line="17" selection-end-column="0" />
703 767
           <folding>
704 768
             <element signature="imports" expanded="true" />
705
-            <element signature="e#233#234#0" expanded="true" />
706
-            <element signature="e#278#279#0" expanded="true" />
707 769
           </folding>
708 770
         </state>
709 771
       </provider>
710 772
     </entry>
711
-    <entry file="file://$PROJECT_DIR$/src/test/java/com/zipcodewilmington/bankaccountlab/CheckingAccountTest.java">
773
+    <entry file="file://$PROJECT_DIR$/src/main/java/com/zipcodewilmington/bankaccountlab/AccountFactory.java">
712 774
       <provider selected="true" editor-type-id="text-editor">
713
-        <state relative-caret-position="448">
714
-          <caret line="28" column="47" lean-forward="false" selection-start-line="28" selection-start-column="47" selection-end-line="28" selection-end-column="47" />
775
+        <state relative-caret-position="128">
776
+          <caret line="8" column="68" lean-forward="true" selection-start-line="8" selection-start-column="68" selection-end-line="8" selection-end-column="68" />
777
+          <folding />
778
+        </state>
779
+      </provider>
780
+    </entry>
781
+    <entry file="file://$PROJECT_DIR$/src/main/java/com/zipcodewilmington/bankaccountlab/AccountType.java">
782
+      <provider selected="true" editor-type-id="text-editor">
783
+        <state relative-caret-position="304">
784
+          <caret line="19" column="41" lean-forward="true" selection-start-line="19" selection-start-column="41" selection-end-line="19" selection-end-column="41" />
715 785
           <folding>
716
-            <element signature="imports" expanded="true" />
717
-            <element signature="e#235#236#0" expanded="true" />
718
-            <element signature="e#281#282#0" expanded="true" />
719
-            <element signature="e#328#329#0" expanded="true" />
720
-            <element signature="e#394#395#0" expanded="true" />
786
+            <element signature="e#144#145#0" expanded="true" />
787
+            <element signature="e#201#202#0" expanded="true" />
788
+            <element signature="e#271#272#0" expanded="true" />
789
+            <element signature="e#329#330#0" expanded="true" />
790
+            <element signature="e#399#400#0" expanded="true" />
791
+            <element signature="e#457#458#0" expanded="true" />
721 792
           </folding>
722 793
         </state>
723 794
       </provider>
724 795
     </entry>
725
-    <entry file="file://$PROJECT_DIR$/src/main/java/com/zipcodewilmington/bankaccountlab/Account.java">
796
+    <entry file="file://$PROJECT_DIR$/src/main/java/com/zipcodewilmington/bankaccountlab/MainApplication.java">
726 797
       <provider selected="true" editor-type-id="text-editor">
727
-        <state relative-caret-position="272">
728
-          <caret line="19" column="13" lean-forward="true" selection-start-line="19" selection-start-column="13" selection-end-line="19" selection-end-column="13" />
798
+        <state relative-caret-position="80">
799
+          <caret line="5" column="13" lean-forward="false" selection-start-line="5" selection-start-column="13" selection-end-line="5" selection-end-column="13" />
729 800
           <folding />
730 801
         </state>
731 802
       </provider>
@@ -733,6 +804,65 @@
733 804
   </component>
734 805
   <component name="masterDetails">
735 806
     <states>
807
+      <state key="ArtifactsStructureConfigurable.UI">
808
+        <settings>
809
+          <artifact-editor />
810
+          <splitter-proportions>
811
+            <option name="proportions">
812
+              <list>
813
+                <option value="0.2" />
814
+              </list>
815
+            </option>
816
+          </splitter-proportions>
817
+        </settings>
818
+      </state>
819
+      <state key="FacetStructureConfigurable.UI">
820
+        <settings>
821
+          <last-edited>No facets are configured</last-edited>
822
+          <splitter-proportions>
823
+            <option name="proportions">
824
+              <list>
825
+                <option value="0.2" />
826
+              </list>
827
+            </option>
828
+          </splitter-proportions>
829
+        </settings>
830
+      </state>
831
+      <state key="GlobalLibrariesConfigurable.UI">
832
+        <settings>
833
+          <splitter-proportions>
834
+            <option name="proportions">
835
+              <list>
836
+                <option value="0.2" />
837
+              </list>
838
+            </option>
839
+          </splitter-proportions>
840
+        </settings>
841
+      </state>
842
+      <state key="JdkListConfigurable.UI">
843
+        <settings>
844
+          <last-edited>1.8</last-edited>
845
+          <splitter-proportions>
846
+            <option name="proportions">
847
+              <list>
848
+                <option value="0.2" />
849
+              </list>
850
+            </option>
851
+          </splitter-proportions>
852
+        </settings>
853
+      </state>
854
+      <state key="ModuleStructureConfigurable.UI">
855
+        <settings>
856
+          <last-edited>bankaccountlab</last-edited>
857
+          <splitter-proportions>
858
+            <option name="proportions">
859
+              <list>
860
+                <option value="0.2" />
861
+              </list>
862
+            </option>
863
+          </splitter-proportions>
864
+        </settings>
865
+      </state>
736 866
       <state key="ProjectJDKs.UI">
737 867
         <settings>
738 868
           <last-edited>1.8</last-edited>
@@ -745,6 +875,18 @@
745 875
           </splitter-proportions>
746 876
         </settings>
747 877
       </state>
878
+      <state key="ProjectLibrariesConfigurable.UI">
879
+        <settings>
880
+          <last-edited>Maven: junit:junit:4.12</last-edited>
881
+          <splitter-proportions>
882
+            <option name="proportions">
883
+              <list>
884
+                <option value="0.2" />
885
+              </list>
886
+            </option>
887
+          </splitter-proportions>
888
+        </settings>
889
+      </state>
748 890
     </states>
749 891
   </component>
750 892
 </project>

+ 12
- 0
src/main/java/com/zipcodewilmington/bankaccountlab/AccountFactory.java Ver arquivo

@@ -0,0 +1,12 @@
1
+package com.zipcodewilmington.bankaccountlab;
2
+
3
+/**
4
+ * Created by leon on 1/10/18.
5
+ */
6
+
7
+public class AccountFactory {
8
+    public static Account getAccount(String type, int amount) {
9
+        AccountType accType = AccountType.valueOf(type.toUpperCase());
10
+        return accType.getAccount(amount);
11
+    }
12
+}

+ 21
- 0
src/main/java/com/zipcodewilmington/bankaccountlab/AccountType.java Ver arquivo

@@ -0,0 +1,21 @@
1
+package com.zipcodewilmington.bankaccountlab;
2
+
3
+enum AccountType {
4
+    SAVINGS {
5
+        @Override
6
+        public Account getAccount(int amount) {
7
+            return new SavingsAccount(amount);
8
+        }
9
+    },
10
+    CHECKING {
11
+        public Account getAccount(int amount) {
12
+            return new CheckingAccount(amount);
13
+        }
14
+    },
15
+    BUSINESS {
16
+        public Account getAccount(int amount) {
17
+            return new BusinessAccount(amount);
18
+        }
19
+    };
20
+    public abstract Account getAccount(int amount);
21
+}

+ 0
- 7
src/main/java/com/zipcodewilmington/bankaccountlab/BankAccount.java Ver arquivo

@@ -1,7 +0,0 @@
1
-package com.zipcodewilmington.bankaccountlab;
2
-
3
-/**
4
- * Created by leon on 1/10/18.
5
- */
6
-public class BankAccount {
7
-}

+ 0
- 4
src/main/java/com/zipcodewilmington/bankaccountlab/BuisnessAccount.java Ver arquivo

@@ -1,4 +0,0 @@
1
-package com.zipcodewilmington.bankaccountlab;
2
-
3
-public class BuisnessAccount {
4
-}

+ 16
- 0
src/main/java/com/zipcodewilmington/bankaccountlab/BusinessAccount.java Ver arquivo

@@ -0,0 +1,16 @@
1
+package com.zipcodewilmington.bankaccountlab;
2
+
3
+public class BusinessAccount extends Account {
4
+    public BusinessAccount(int amount) {
5
+            super(amount);
6
+    }
7
+
8
+    @Override
9
+    public boolean withdrawBalance(int withdrawalAmount) {
10
+        if (withdrawalAmount <= super.getBalance()) {
11
+            super.subtractBalance(withdrawalAmount);
12
+            return true;
13
+        }
14
+        return false;
15
+    }
16
+}

+ 26
- 0
src/test/java/com/zipcodewilmington/bankaccountlab/AccountFactoryTest.java Ver arquivo

@@ -0,0 +1,26 @@
1
+package com.zipcodewilmington.bankaccountlab;
2
+
3
+import org.junit.Test;
4
+
5
+import static org.junit.Assert.*;
6
+
7
+public class AccountFactoryTest {
8
+
9
+    @Test
10
+    public void getBuisnessAccount() {
11
+       Account ba = AccountFactory.getAccount("Business", 10000);
12
+       assertTrue(ba.getClass() == BusinessAccount.class);
13
+    }
14
+
15
+    @Test
16
+    public void getSavingsAccount() {
17
+        Account sa = AccountFactory.getAccount("Savings", 1000);
18
+        assertTrue(sa.getClass() == SavingsAccount.class);
19
+    }
20
+
21
+    @Test
22
+    public void getCheckingAccount() {
23
+        Account ca = AccountFactory.getAccount("Checking", 1000);
24
+        assertTrue(ca.getClass() == CheckingAccount.class);
25
+    }
26
+}

+ 8
- 0
src/test/java/com/zipcodewilmington/bankaccountlab/AccountTest.java Ver arquivo

@@ -48,6 +48,14 @@ public class AccountTest {
48 48
     }
49 49
 
50 50
     @Test
51
+    public void subtractBalanceTest() {
52
+        int expected = 500;
53
+        int actual = ta.subtractBalance(500).getBalance();
54
+        assertEquals(expected, actual);
55
+    }
56
+
57
+
58
+    @Test
51 59
     public void mockObjectExtendsAbstract() {
52 60
         assertTrue(ta instanceof Account);
53 61
     }

+ 0
- 7
src/test/java/com/zipcodewilmington/bankaccountlab/BankAccountTest.java Ver arquivo

@@ -1,7 +0,0 @@
1
-package com.zipcodewilmington.bankaccountlab;
2
-
3
-/**
4
- * Created by leon on 1/10/18.
5
- */
6
-public class BankAccountTest {
7
-}

+ 37
- 0
src/test/java/com/zipcodewilmington/bankaccountlab/BusinessAccountTest.java Ver arquivo

@@ -0,0 +1,37 @@
1
+package com.zipcodewilmington.bankaccountlab;
2
+
3
+import org.junit.Before;
4
+import org.junit.Test;
5
+
6
+import static org.junit.Assert.*;
7
+
8
+public class BusinessAccountTest {
9
+    private BusinessAccount ba;
10
+
11
+    @Before
12
+    public void setUp() {
13
+        ba = new BusinessAccount(10_000);
14
+    }
15
+
16
+    @Test
17
+    public void constructorTest() {
18
+        assertTrue(ba.getClass() == BusinessAccount.class);
19
+    }
20
+
21
+    @Test
22
+    public void withdrawBalanceTruthyTest() {
23
+        assertTrue(ba.withdrawBalance(100));
24
+    }
25
+
26
+    @Test
27
+    public void withdrawBalanceFalseyTest() {
28
+        assertFalse(ba.withdrawBalance(100_000));
29
+    }
30
+
31
+    @Test
32
+    public void depositMoneyTest() {
33
+        int expected = 25_000;
34
+        int actual = ba.addBalance(15_000).getBalance();
35
+        assertEquals(expected, actual);
36
+    }
37
+}