[BUG] Separate UI and Config Modules #53
Labels
bug
Something isn't working
good first issue
Good for newcomers
Module: Config
This issue relates to the Config module
Module: UI
This issue relates to UI
need analysis
review is needed
Description
Issue
There is a lot of business logic currently mixed with the UI in the Config module. This is a contributing factor to the mess that is the config module.
Steps to recreate
N/A
Solution
Separate the UI and business logic in the config module.
config.newConfigFile
is the most egregious example of this, however many of the methods in this module exhibit similar issues.Should move business logic into separate, unit-testable, methods and move the UI into the UI module. See
UI.standardGrading
for an example of how this was done in the past.Ideally, all user input should be handled by the
uiHelpers.getUserInput
method.The other major thing for consideration is how we want to read the config. Currently, we are doing it with a single call to
config.readConfig
in the main method, which handles the reading and selection in the event that there are many config files. I also want to separate the business logic (getting the list of available configs, reading the selected one) and the UI (selecting the config file).Acceptance Criteria
uiHelpers.getUserInput
The text was updated successfully, but these errors were encountered: