AY2324S2-CS2113T-T09-4 / tp

0 stars 6 forks source link

integration test + minor exception fixes #235

Closed JustinSoh closed 7 months ago

JustinSoh commented 7 months ago

Code Changed [X] Split parseHistoryAndLatest into parseHistory and parseLatest as the exceptions for latest and history are slightly different. [X] Split validateFilter into validateLatestFilter and validateHistoryFilter. [X] Modified HISTORY and LATEST exception to be standardised to ErrorConstant.INVALID_LATEST_FILTER_ERROR ErrorConstant.INVALID_HISTORY_FILTER_ERROR, ErrorConstant.INSUFFICIENT_LATEST_FILTER_ERROR and ErrorConstant.INSUFFICIENT_HISTORY_FILTER_ERROR.

@rouvinerh @L5-Z - take note as we will need to change screenshots for these as I included a more verbose description

Testing Functions [X] Integration Testing for addHealthAndShowLatest_correctInput_expectCorrectLatestOutput to add all health input and have the correct latest output [X] Integration Testing for addBmiAndShowLatest_incorrectInput_expectErrors to throw errors for all health Input [X] Created TestHelper to help with output strings used for testing [X] Increase Output class coverage