pybliometrics-dev / pybliometrics

Python-based API-Wrapper to access Scopus
https://pybliometrics.readthedocs.io/en/stable/
Other
401 stars 124 forks source link

Fix tests #313

Closed nils-herrmann closed 4 months ago

nils-herrmann commented 7 months ago

pybliometrics version: 3.8

Code to reproduce the bug: $nosetests --verbose

Expected behavior: No errors or fails

List of tests that fail or have an error:

  1. pybliometrics.scopus.tests.test_AuthorRetrieval.test_affiliation_history ... ERROR
  2. pybliometrics.scopus.tests.test_AuthorRetrieval.test_estimate_uniqueness ... FAIL
  3. pybliometrics.scopus.tests.test_AuthorRetrieval.test_historical_identifier ... FAIL
  4. pybliometrics.scopus.tests.test_AuthorRetrieval.test_get_documents ... FAIL
  5. pybliometrics.scopus.tests.test_AuthorRetrieval.test_warning_without_forwarding ... ERROR
  6. pybliometrics.scopus.tests.test_AuthorRetrieval.test_warning_with_forwarding ... ERROR
  7. pybliometrics.scopus.tests.test_SerialTitle.test_citescoreyearinfolist ... FAIL
Michael-E-Rose commented 7 months ago

These are not bugs, they often mean that past commits broke something.

I have different fails though:

  1. pybliometrics.scopus.tests.test_AuthorRetrieval.test_affiliation_history fails because of pybliometrics/scopus/utils/parse_content.py
  2. pybliometrics.scopus.tests.test_CitationOverview.test_authors fails for an unknown change, likely in the API
  3. pybliometrics.scopus.tests.test_AuthorRetrieval.test_historical_identifier fails because of a change in the API
  4. pybliometrics.scopus.tests.test_SerialTitle.test_citescoreyearinfolist fails because of a mistake in the test code
  5. pybliometrics.scopus.tests.test_PlumXMetrics fails because of a change in the API

Also, when you're on Linux or Mac, you should use nosetests3!

I will deal with the failues 2 through 5. Can you please fix the cause for the first failure, @nils-herrmann ?

Michael-E-Rose commented 7 months ago

Re my second point I reached out to the Scopus folks to verify that this no bug.

Michael-E-Rose commented 4 months ago

I updated all test scripts in 6023daf3ee5df63aadd590f32bb7593764aaed28, but the first issue remains. I think the author information in the Citation Overview API is gone for good.