Skip to content
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

Add option to use the Citoid API in Zotero format #3732

Merged
merged 29 commits into from May 15, 2021

Conversation

nemobis
Copy link
Contributor

@nemobis nemobis commented May 15, 2021

The only difference is that it takes GET requests rather than POST,
and the URL is passed in the URL rather than POST data.

public function testUnPaywall2() : void {
$text = "{{cite journal|doi=10.1145/358589.358596|doi-access=free}}";
$text = "{{cite journal|doi=10.1007/s11075-018-0599-7}}";
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

doi:10.1007/s11075-018-0599-7 is actually a case which should find an URL from http://arxiv.org/abs/1804.09042 , but I suppose that's added as parameter rather than as URL. I'm not actually sure it's that important to test that doi-access=free citations are left alone.

The only difference is that it takes GET requests rather than POST,
and the URL is passed in the URL rather than POST data.
* Actually test Unpaywall in Unpaywall tests.
* Remove broken tests or parameters for SemanticScholar. They are no
  longer relevant now that SemanticScholar has removed most of the
  content it had.
* Also remove an unnecessary check for SemanticScholar output from the
  Unpaywall API.
* Just remove the broken SemanticScholar test
They're valid repository URLs.
2) TemplateTest::testGoogleBooksExpansionNEW
Failed asserting that two strings are identical.
--- Expected
+++ Actual
@@ @@
-'cite book'
+'cite web'
@nemobis
Copy link
Contributor Author

nemobis commented May 15, 2021

Verbose phpunit says things like

>Remedial work to clean up templates</span>F
<span class='subsubitem'>  >Could not resolve URL https://www.nytimes.com/2018/06/11/technology/net-neutrality-repeal.html</span>F
<span class='subsubitem'>  >Could not resolve URL https://www.ncbi.nlm.nih.gov/books/NBK24662/</span>F
<span class='phase'>

Also change a biorxiv test which was the only one left failing.
@nemobis
Copy link
Contributor Author

nemobis commented May 15, 2021

I have no idea how requires_zotero() is supposed to work, but it's not working, and we don't really need it when the tests are not disabled, so I'm just emptying it.

@codecov
Copy link

codecov bot commented May 15, 2021

Codecov Report

Merging #3732 (be9d8b4) into master (a0b0baf) will decrease coverage by 0.41%.
The diff coverage is 53.33%.

Impacted file tree graph

@@             Coverage Diff              @@
##             master    #3732      +/-   ##
============================================
- Coverage     85.60%   85.19%   -0.42%     
- Complexity     3765     3833      +68     
============================================
  Files            12       12              
  Lines          7176     7274      +98     
============================================
+ Hits           6143     6197      +54     
- Misses         1033     1077      +44     
Impacted Files Coverage Δ Complexity Δ
Template.php 86.68% <52.57%> (-0.73%) 3285.00 <0.00> (+66.00) ⬇️
Zotero.php 92.32% <62.50%> (+0.57%) 263.00 <0.00> (+2.00)

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update f7b4f1a...be9d8b4. Read the comment docs.

@GlazerMann GlazerMann merged commit 1c5b6a9 into ms609:master May 15, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants