Skip to content

Increase test coverage #54

Open
Open
@Nathan-Nesbitt

Description

@Nathan-Nesbitt

The following is similar to the current test coverage for the library:

----------- coverage: platform linux, python 3.9.7-final-0 -----------
Name                            Stmts   Miss  Cover   Missing
-------------------------------------------------------------
spylib/__init__.py                  3      0   100%
spylib/constants.py                 4      0   100%
spylib/exceptions.py               10      0   100%
spylib/oauth/__init__.py            2      0   100%
spylib/oauth/redirects.py          18      4    78%   61-73
spylib/oauth/router.py             49      8    84%   47, 49, 79-80, 96-98, 101
spylib/oauth/validations.py        29      2    93%   19, 48
spylib/token.py                   171     14    92%   97, 131-132, 140, 157-158, 184, 202, 259, 263, 288, 331-336
spylib/utils/__init__.py            7      0   100%
spylib/utils/domain.py             13      1    92%   9
spylib/utils/hmac.py               17      5    71%   10, 16-19
spylib/utils/httpclient.py         11      1    91%   17
spylib/utils/jwtoken.py            34      7    79%   54-56, 84-87, 92
spylib/utils/misc.py                6      0   100%
spylib/utils/session_token.py      51      0   100%
-------------------------------------------------------------
TOTAL                             425     42    90%

I think it might be useful to write some more tests for the following sections? As it is a little tricky to tell if changes are impacting different parts of the library at the moment.

  • spylib/oauth/redirects.py
  • spylib/oauth/router.py
  • spylib/token.py

Especially the OAuth section, as the current tests are only testing a single run-through of the OAuth process and doesn't check erroneous cases and how they are handled.

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions