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

Fixed test_bibtex unit test, updated CONTRIBUTING.md #525

Open
wants to merge 2 commits into
base: develop
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
13 changes: 7 additions & 6 deletions .github/CONTRIBUTING.md
Original file line number Diff line number Diff line change
Expand Up @@ -16,12 +16,13 @@ Additionally, if you are interesting in contributing to the codebase, submit a p

## How to contribute

1. Create a fork of `scholarly-python-package/scholarly` repository.
2. If you add a new feature, try to include tests in already existing test cases, or create a new test case if that is not possible.
3. Make sure the unit tests pass before raising a PR. For all the unit tests to pass, you typically need to setup a premium proxy service such as `ScraperAPI` or `Luminati` (`Bright Data`). If you do not have an account, you may try to use `FreeProxy`. Without a proxy, 6 out of 17 test cases will be skipped.
4. Check that the documentatation is consistent with the code. Check that the documentation builds successfully.
5. Submit a PR, with `develop` as your base branch.
6. After an initial code review by the maintainers, the unit tests will be run with the `ScraperAPI` key stored in the Github repository. Passing all tests cases is necessary before merging your PR.
1. Create a fork of `scholarly-python-package/scholarly` repository. Make sure that "Copy the main branch only" is **not** checked off.
2. After cloning your fork and checking out into the develop branch, run `python setup.py --help-commands` for more info on how to install dependencies and build. You may need to run it with `sudo`.
3. If you add a new feature, try to include tests in already existing test cases, or create a new test case if that is not possible. For a comprehensive output, run `python -m unittest -v test_module.py`
4. Make sure the unit tests pass before raising a PR. For all the unit tests to pass, you typically need to setup a premium proxy service such as `ScraperAPI` or `Luminati` (`Bright Data`). By default, `python setup.py install` will get `FreeProxy`. Without a proxy, 6 out of 17 test cases will be skipped.
5. Check that the documentatation is consistent with the code. Check that the documentation builds successfully.
6. Submit a PR, with `develop` as your base branch.
7. After an initial code review by the maintainers, the unit tests will be run with the `ScraperAPI` key stored in the Github repository. Passing all tests cases is necessary before merging your PR.


## Build Docs
Expand Down
2 changes: 1 addition & 1 deletion test_module.py
Original file line number Diff line number Diff line change
Expand Up @@ -690,7 +690,7 @@ def test_bibtex(self):
Test that we get the BiBTeX entry correctly
"""

with open("testdata/bibtex.txt", "r") as f:
with open("testdata/test_bibtex_result.txt", "r") as f:
expected_result = "".join(f.readlines())

pub = scholarly.search_single_pub("A distribution-based clustering algorithm for mining in large "
Expand Down