Skip to content

Commit

Permalink
Added more comments to LogicTest
Browse files Browse the repository at this point in the history
  • Loading branch information
AlexLMeow authored Sep 8, 2016
1 parent 4752b95 commit 282fb15
Showing 1 changed file with 8 additions and 4 deletions.
12 changes: 8 additions & 4 deletions test/java/seedu/addressbook/logic/LogicTest.java
Original file line number Diff line number Diff line change
Expand Up @@ -36,11 +36,12 @@ public class LogicTest {
*/
@Rule
public TemporaryFolder saveFolder = new TemporaryFolder();

private StorageFile saveFile;
private AddressBook addressBook;

// direct access to the storage file used by the Logic object. Useful for verifying save file state.
private StorageFile saveFile;
// direct access to the addressbook used by the Logic object. Useful for verifying internal addressbook state.
private AddressBook addressBook;
private Logic logic;
private Person testPerson;

@Before
public void setup() throws Exception {
Expand All @@ -50,6 +51,9 @@ public void setup() throws Exception {
logic = new Logic(saveFile, addressBook);
}

/**
* Verifies that the save file contents and the internal address book are synchronised.
*/
private void assertSaveFileUpToDate() throws StorageFile.StorageOperationException {
assertEquals(addressBook, saveFile.load());
}
Expand Down

0 comments on commit 282fb15

Please sign in to comment.