-
Notifications
You must be signed in to change notification settings - Fork 210
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
Correct API docs path and fix pytest invocation #379
Conversation
The earlier location http://127.0.0.1:8000/api/docs was a 404. As the urls.py suggests, the README now reflects http://127.0.0.1:8000/api/schema/swagger-ui/ After the first install, activating the venv is done prior to installing pytest, thus the system default pytest is being called. It is either required to reactive venv or run pytest via python -m. Signed-off-by: Hritik Vijay <[email protected]>
@@ -206,7 +206,7 @@ Run Tests | |||
Use these commands to run code style checks and the test suite:: | |||
|
|||
black -l 100 --check . | |||
DJANGO_DEV=1 pytest | |||
DJANGO_DEV=1 python -m pytest |
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.
If you are in an activated virtualenv, pytest should work. Did you experience an issue here?
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.
The pytest bug is weird. @Hritik14 could you try updating the venv pytest to latest and try running |
@sbs2001 I think you're right. It is failing because the tests are only compatible with pytest version shipped with the project requirements. As you can see, after first installation, Maybe we can look into this in #348. In any way, for now, I think the pytest invocation should always be the one shipped with the project itself so as to not just break due to any system update. |
@Hritik14 thanks for confirming. Do you mind repasting your comment at #348, that'll be handy. We'll use As for the api doc related changes. That's a good check. IMHO the docs should be at http://127.0.0.1:8000/api/docs, the |
Here is the entire conversation: aboutcode-org#379 Signed-off-by: Hritik Vijay <[email protected]>
As mentioned in the previous version of README.rst, the docs should be at /api/docs. Signed-off-by: Hritik Vijay <[email protected]>
@sbs2001 Your wish is my command. :) |
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.
@Hritik14 thanks for the PR, I'm merging this
Here is the entire conversation: aboutcode-org#379 Signed-off-by: Hritik Vijay <[email protected]> Signed-off-by: Pushpit <[email protected]>
Here is the entire conversation: aboutcode-org#379 Signed-off-by: Hritik Vijay <[email protected]> Signed-off-by: Pushpit <[email protected]>
The earlier location http://127.0.0.1:8000/api/docs was a 404. As the
urls.py suggests, the README now reflects http://127.0.0.1:8000/api/schema/swagger-ui/
After the first install, activating the venv is done prior to installing
pytest, thus the system default pytest is being called. It is either
required to reactive venv or run pytest via python -m.
Signed-off-by: Hritik Vijay [email protected]