Browse Source

Merge pull request #314 from marcospereirampj/fix/313-unit-tests-are-importing-keycloak-files-from-the-repository

Fix/313 unit tests are importing keycloak files from the repository
pull/316/head
Richard Nemeth 3 years ago
committed by GitHub
parent
commit
3a3d4a4ae7
No known key found for this signature in database GPG Key ID: 4AEE18F83AFDEB23
  1. 2
      docs/source/conf.py
  2. 8
      setup.py
  3. 0
      src/keycloak/__init__.py
  4. 0
      src/keycloak/_version.py
  5. 0
      src/keycloak/authorization/__init__.py
  6. 0
      src/keycloak/authorization/permission.py
  7. 0
      src/keycloak/authorization/policy.py
  8. 0
      src/keycloak/authorization/role.py
  9. 0
      src/keycloak/connection.py
  10. 0
      src/keycloak/exceptions.py
  11. 0
      src/keycloak/keycloak_admin.py
  12. 0
      src/keycloak/keycloak_openid.py
  13. 0
      src/keycloak/urls_patterns.py
  14. 12
      tox.ini

2
docs/source/conf.py

@ -41,7 +41,7 @@ extensions = [
] ]
autoapi_type = "python" autoapi_type = "python"
autoapi_dirs = ["../../keycloak"]
autoapi_dirs = ["../../src/keycloak"]
autoapi_root = "reference" autoapi_root = "reference"
autoapi_keep_files = False autoapi_keep_files = False
autoapi_add_toctree_entry = False autoapi_add_toctree_entry = False

8
setup.py

@ -1,6 +1,7 @@
# -*- coding: utf-8 -*- # -*- coding: utf-8 -*-
import re import re
from setuptools import setup
from setuptools import find_packages, setup
with open("README.md", "r") as fh: with open("README.md", "r") as fh:
long_description = fh.read() long_description = fh.read()
@ -15,7 +16,7 @@ with open("docs-requirements.txt", "r") as fh:
docs_reqs = fh.read().split("\n") docs_reqs = fh.read().split("\n")
VERSIONFILE = "keycloak/_version.py"
VERSIONFILE = "src/keycloak/_version.py"
verstrline = open(VERSIONFILE, "rt").read() verstrline = open(VERSIONFILE, "rt").read()
VSRE = r"^__version__ = ['\"]([^'\"]*)['\"]" VSRE = r"^__version__ = ['\"]([^'\"]*)['\"]"
mo = re.search(VSRE, verstrline, re.M) mo = re.search(VSRE, verstrline, re.M)
@ -35,7 +36,8 @@ setup(
description="python-keycloak is a Python package providing access to the Keycloak API.", description="python-keycloak is a Python package providing access to the Keycloak API.",
long_description=long_description, long_description=long_description,
long_description_content_type="text/markdown", long_description_content_type="text/markdown",
packages=["keycloak", "keycloak.authorization"],
packages=find_packages("src"),
package_dir={"": "src"},
install_requires=reqs, install_requires=reqs,
tests_require=dev_reqs, tests_require=dev_reqs,
extras_require={"docs": docs_reqs}, extras_require={"docs": docs_reqs},

0
keycloak/__init__.py → src/keycloak/__init__.py

0
keycloak/_version.py → src/keycloak/_version.py

0
keycloak/authorization/__init__.py → src/keycloak/authorization/__init__.py

0
keycloak/authorization/permission.py → src/keycloak/authorization/permission.py

0
keycloak/authorization/policy.py → src/keycloak/authorization/policy.py

0
keycloak/authorization/role.py → src/keycloak/authorization/role.py

0
keycloak/connection.py → src/keycloak/connection.py

0
keycloak/exceptions.py → src/keycloak/exceptions.py

0
keycloak/keycloak_admin.py → src/keycloak/keycloak_admin.py

0
keycloak/keycloak_openid.py → src/keycloak/keycloak_openid.py

0
keycloak/urls_patterns.py → src/keycloak/urls_patterns.py

12
tox.ini

@ -10,9 +10,9 @@ deps =
isort isort
flake8 flake8
commands = commands =
black --check --diff keycloak tests docs
isort -c --df keycloak tests docs
flake8 keycloak tests docs
black --check --diff src/keycloak tests docs setup.py
isort -c --df src/keycloak tests docs setup.py
flake8 src/keycloak tests docs setup.py
[testenv:apply-check] [testenv:apply-check]
deps = deps =
@ -20,9 +20,9 @@ deps =
isort isort
flake8 flake8
commands = commands =
black -C keycloak tests docs
black keycloak tests docs
isort keycloak tests docs
black -C src/keycloak tests docs setup.py
black src/keycloak tests docs setup.py
isort src/keycloak tests docs setup.py
[testenv:docs] [testenv:docs]
deps = deps =

Loading…
Cancel
Save