Switch to full app paths
Instead of inserting the path of the apps into the Python app, the apps are now referenced by their full import path. This solves name clashes with external or native Python libraries. Example: Mayan statistics app vs. Python new statistics library. Every app reference is now prepended with 'mayan.apps'. Existing config.yml files need to be updated manually. Signed-off-by: Roberto Rosario <roberto.rosario.gonzalez@gmail.com>
This commit is contained in:
@@ -4,7 +4,7 @@ from __future__ import unicode_literals
|
||||
|
||||
from django.test import override_settings
|
||||
|
||||
from common.tests import BaseTestCase, GenericViewTestCase
|
||||
from mayan.apps.common.tests import BaseTestCase, GenericViewTestCase
|
||||
|
||||
from .mixins import DocumentTestMixin
|
||||
|
||||
|
||||
@@ -10,7 +10,7 @@ from django.utils.encoding import force_text
|
||||
from django_downloadview import assert_download_response
|
||||
from rest_framework import status
|
||||
|
||||
from rest_api.tests import BaseAPITestCase
|
||||
from mayan.apps.rest_api.tests import BaseAPITestCase
|
||||
|
||||
from ..models import Document, DocumentType
|
||||
from ..permissions import (
|
||||
|
||||
@@ -7,8 +7,8 @@ import os
|
||||
from django.contrib.contenttypes.models import ContentType
|
||||
from django.utils.encoding import force_text
|
||||
|
||||
from converter.models import Transformation
|
||||
from converter.permissions import permission_transformation_delete
|
||||
from mayan.apps.converter.models import Transformation
|
||||
from mayan.apps.converter.permissions import permission_transformation_delete
|
||||
|
||||
from ..literals import PAGE_RANGE_ALL
|
||||
from ..models import DeletedDocument, Document, DocumentType
|
||||
|
||||
@@ -5,7 +5,7 @@ from __future__ import unicode_literals
|
||||
from actstream.models import Action
|
||||
from django_downloadview import assert_download_response
|
||||
|
||||
from user_management.tests.literals import (
|
||||
from mayan.apps.user_management.tests.literals import (
|
||||
TEST_USER_PASSWORD, TEST_USER_USERNAME
|
||||
)
|
||||
|
||||
|
||||
@@ -6,7 +6,7 @@ import time
|
||||
|
||||
from django.urls import reverse
|
||||
|
||||
from acls.models import AccessControlList
|
||||
from mayan.apps.acls.models import AccessControlList
|
||||
|
||||
from ..links import (
|
||||
link_document_restore, link_document_version_download,
|
||||
|
||||
@@ -5,7 +5,7 @@ import time
|
||||
|
||||
from django.test import override_settings
|
||||
|
||||
from common.tests import BaseTestCase
|
||||
from mayan.apps.common.tests import BaseTestCase
|
||||
|
||||
from ..literals import STUB_EXPIRATION_INTERVAL
|
||||
from ..models import (
|
||||
|
||||
@@ -2,10 +2,10 @@ from __future__ import unicode_literals
|
||||
|
||||
from django.test import override_settings
|
||||
|
||||
from common.tests import BaseTestCase
|
||||
from documents.permissions import permission_document_view
|
||||
from documents.search import document_search, document_page_search
|
||||
from documents.tests import DocumentTestMixin
|
||||
from mayan.apps.common.tests import BaseTestCase
|
||||
from mayan.apps.documents.permissions import permission_document_view
|
||||
from mayan.apps.documents.search import document_search, document_page_search
|
||||
from mayan.apps.documents.tests import DocumentTestMixin
|
||||
|
||||
|
||||
@override_settings(OCR_AUTO_OCR=False)
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
from __future__ import unicode_literals
|
||||
|
||||
from common.tests import BaseTestCase
|
||||
from mayan.apps.common.tests import BaseTestCase
|
||||
|
||||
from ..utils import parse_range
|
||||
|
||||
|
||||
Reference in New Issue
Block a user