- 
          
 - 
                Notifications
    
You must be signed in to change notification settings  - Fork 3k
 
Description
Is your suggestion for improvement related to a problem? Please describe.
The importDatabase() method in OvidImporter has grown into a long method that mixes multiple functionalities including record splitting, per-field parsing, regex handling for Source fields, and final cleanup. This makes it harder to understand, test, and maintain.
Describe the solution you'd like
I’d like to refactor importDatabase() by extracting several small private helper methods (parseSource(), parseField(), normalizeContributors(), and resolveEntryType()) while preserving all current behavior and public APIs. The goal is purely to improve readability and separation of concerns, not to change functionality.
Additional context
This refactoring proposal was discussed and approved on the JabRef Gitter channel.
Would you prefer helper methods like these to be annotated with @VisibleForTesting and have direct unit tests, or should testing rely solely on the existing integration-level coverage for OvidImporter? I understand there are different schools of thought on this and would like to follow JabRef’s convention.