-
-
Notifications
You must be signed in to change notification settings - Fork 2.6k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Endnote importer test #321
Conversation
Could you add some real EndNote entries? Currently, there seem only test entries to be tested, but no real-life entries. Minor comments
|
Please rebase on master so that circleci and codecov will show correct results. |
We discovered, that EndNote is also capable of importing EndNote imports both: The RISFormat and the EndNote format (es exported by JabRef). I vote for removing the EndNote importer and focus on the RisImporter. Furthermore, I vote for removing the EndNote exporter and focus on testing the RISExporter. |
I started a discussion at jabref-users. It seems that users want to keep support for the old format. |
Just leave it as it is right now. :) |
OK for me even though some minor issues remain: https://codecov.io/github/JabRef/jabref/src/main/java/net/sf/jabref/importer/fileformat/EndnoteImporter.java?ref=6fb8635b36920b760e3e003d169e4a4fb78626ef - line 194, line 227. |
public void setUp() throws Exception { | ||
if (Globals.prefs == null) { | ||
Globals.prefs = JabRefPreferences.getInstance(); | ||
} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
You do not need the if-condition here. Just set the Globals.prefs
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Reference in the docs: https://github.com/JabRef/jabref/wiki/Code-Howtos#preferences-in-tests
Fixed the mentioned issues and did some more refactoring. |
assertEquals("testU", be4.getField("url")); | ||
assertEquals("testV", be4.getField("volume")); | ||
} | ||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Please split this in 3 different tests.
The tests with small test files should be tested by inline strings as described here: #354 (comment) |
I agree with using direct equals tests than using bib files. However, tests with full bib files should not vanish. We told the students to have a look at GVKParserTest.java and do similar testing. 😇 |
Coverage 97.90%. I don't see more test cases to turn the the yellow lines into green ones. If the test cases and test files get speaking names, I'm fine with it. @tobiasdiez Do you agree? |
Yes, looks good to me 👍 |
I used The |
No description provided.