Skip to content
This repository has been archived by the owner on Mar 5, 2023. It is now read-only.

Commit

Permalink
AddressBookSystemTest: remove unnecessary catch block
Browse files Browse the repository at this point in the history
The code in the `try` block does not throw any checked exceptions.
  • Loading branch information
pyokagan committed Aug 9, 2018
1 parent 73693de commit 1c39319
Showing 1 changed file with 7 additions and 11 deletions.
18 changes: 7 additions & 11 deletions src/test/java/systemtests/AddressBookSystemTest.java
Original file line number Diff line number Diff line change
Expand Up @@ -274,17 +274,13 @@ protected void assertStatusBarUnchangedExceptSyncStatus() {
* Asserts that the starting state of the application is correct.
*/
private void assertApplicationStartingStateIsCorrect() {
try {
assertEquals("", getCommandBox().getInput());
assertEquals("", getResultDisplay().getText());
assertListMatching(getPersonListPanel(), getModel().getFilteredPersonList());
assertEquals(MainApp.class.getResource(FXML_FILE_FOLDER + DEFAULT_PAGE), getBrowserPanel().getLoadedUrl());
assertEquals(Paths.get(".").resolve(testApp.getStorageSaveLocation()).toString(),
getStatusBarFooter().getSaveLocation());
assertEquals(SYNC_STATUS_INITIAL, getStatusBarFooter().getSyncStatus());
} catch (Exception e) {
throw new AssertionError("Starting state is wrong.", e);
}
assertEquals("", getCommandBox().getInput());
assertEquals("", getResultDisplay().getText());
assertListMatching(getPersonListPanel(), getModel().getFilteredPersonList());
assertEquals(MainApp.class.getResource(FXML_FILE_FOLDER + DEFAULT_PAGE), getBrowserPanel().getLoadedUrl());
assertEquals(Paths.get(".").resolve(testApp.getStorageSaveLocation()).toString(),
getStatusBarFooter().getSaveLocation());
assertEquals(SYNC_STATUS_INITIAL, getStatusBarFooter().getSyncStatus());
}

/**
Expand Down

0 comments on commit 1c39319

Please sign in to comment.