From nobody Thu Apr 25 21:47:17 2024 Delivered-To: importer@patchew.org Received-SPF: pass (zoho.com: domain of redhat.com designates 209.132.183.28 as permitted sender) client-ip=209.132.183.28; envelope-from=patchew-devel-bounces@redhat.com; helo=mx1.redhat.com; Authentication-Results: mx.zohomail.com; spf=pass (zoho.com: domain of redhat.com designates 209.132.183.28 as permitted sender) smtp.mailfrom=patchew-devel-bounces@redhat.com; dmarc=pass(p=none dis=none) header.from=redhat.com Return-Path: Received: from mx1.redhat.com (mx1.redhat.com [209.132.183.28]) by mx.zohomail.com with SMTPS id 1529936464254676.1824219819894; Mon, 25 Jun 2018 07:21:04 -0700 (PDT) Received: from smtp.corp.redhat.com (int-mx12.intmail.prod.int.phx2.redhat.com [10.5.11.27]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mx1.redhat.com (Postfix) with ESMTPS id B7D1F81DF2; Mon, 25 Jun 2018 14:21:03 +0000 (UTC) Received: from colo-mx.corp.redhat.com (colo-mx02.intmail.prod.int.phx2.redhat.com [10.5.11.21]) by smtp.corp.redhat.com (Postfix) with ESMTPS id A8874A20C0; Mon, 25 Jun 2018 14:21:03 +0000 (UTC) Received: from lists01.pubmisc.prod.ext.phx2.redhat.com (lists01.pubmisc.prod.ext.phx2.redhat.com [10.5.19.33]) by colo-mx.corp.redhat.com (Postfix) with ESMTP id 9CAAB4A460; Mon, 25 Jun 2018 14:21:03 +0000 (UTC) Received: from smtp.corp.redhat.com (int-mx03.intmail.prod.int.rdu2.redhat.com [10.11.54.3]) by lists01.pubmisc.prod.ext.phx2.redhat.com (8.13.8/8.13.8) with ESMTP id w5PEKue1007761 for ; Mon, 25 Jun 2018 10:20:56 -0400 Received: by smtp.corp.redhat.com (Postfix) id 546601117622; Mon, 25 Jun 2018 14:20:56 +0000 (UTC) Received: from donizetti.redhat.com (ovpn-112-27.ams2.redhat.com [10.36.112.27]) by smtp.corp.redhat.com (Postfix) with ESMTP id A4D821117620 for ; Mon, 25 Jun 2018 14:20:53 +0000 (UTC) From: Paolo Bonzini To: patchew-devel@redhat.com Date: Mon, 25 Jun 2018 16:20:53 +0200 Message-Id: <20180625142053.4118-1-pbonzini@redhat.com> X-Scanned-By: MIMEDefang 2.78 on 10.11.54.3 X-loop: patchew-devel@redhat.com Subject: [Patchew-devel] [PATCH v2] testcases: use full path when importing patchewtest X-BeenThere: patchew-devel@redhat.com X-Mailman-Version: 2.1.12 Precedence: junk List-Id: Patchew development and discussion list List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Sender: patchew-devel-bounces@redhat.com Errors-To: patchew-devel-bounces@redhat.com X-Scanned-By: MIMEDefang 2.84 on 10.5.11.27 X-Greylist: Sender IP whitelisted, not delayed by milter-greylist-4.5.16 (mx1.redhat.com [10.5.110.25]); Mon, 25 Jun 2018 14:21:03 +0000 (UTC) X-ZohoMail: RSF_0 Z_629925259 SPT_0 Content-Type: text/plain; charset="utf-8" The actual path to patchewtest is tests.patchewtest; "from patchewtest" breaks when invoking "./manage.py test tests.test_project". However, the relative path "from .patchewtest" breaks when invoking "./manage.py test tests". Signed-off-by: Paolo Bonzini --- tests/test_diff.py | 2 +- tests/test_git.py | 2 +- tests/test_import.py | 2 +- tests/test_mbox.py | 2 +- tests/test_message.py | 2 +- tests/test_model.py | 2 +- tests/test_project.py | 2 +- tests/test_rest.py | 2 +- tests/test_tags.py | 2 +- tests/test_testing.py | 2 +- 10 files changed, 10 insertions(+), 10 deletions(-) diff --git a/tests/test_diff.py b/tests/test_diff.py index 735c4e7..5aaf543 100755 --- a/tests/test_diff.py +++ b/tests/test_diff.py @@ -11,7 +11,7 @@ import sys import os sys.path.append(os.path.dirname(__file__)) -from patchewtest import PatchewTestCase, main +from tests.patchewtest import PatchewTestCase, main =20 class DiffTest(PatchewTestCase): =20 diff --git a/tests/test_git.py b/tests/test_git.py index d64f901..e3da71f 100755 --- a/tests/test_git.py +++ b/tests/test_git.py @@ -11,7 +11,7 @@ import sys import os sys.path.append(os.path.dirname(__file__)) -from patchewtest import PatchewTestCase, main +from tests.patchewtest import PatchewTestCase, main import shutil import subprocess from api.models import Message diff --git a/tests/test_import.py b/tests/test_import.py index 3ad7592..5693d7e 100755 --- a/tests/test_import.py +++ b/tests/test_import.py @@ -11,7 +11,7 @@ import sys import os sys.path.append(os.path.dirname(__file__)) -from patchewtest import PatchewTestCase, main +from tests.patchewtest import PatchewTestCase, main import json from api.models import Message, Project =20 diff --git a/tests/test_mbox.py b/tests/test_mbox.py index b63608d..f003844 100755 --- a/tests/test_mbox.py +++ b/tests/test_mbox.py @@ -12,7 +12,7 @@ import os import sys import mbox sys.path.append(os.path.dirname(__file__)) -from patchewtest import PatchewTestCase, main +from tests.patchewtest import PatchewTestCase, main =20 class MboxTest(PatchewTestCase): =20 diff --git a/tests/test_message.py b/tests/test_message.py index 8f2f75e..9448aee 100755 --- a/tests/test_message.py +++ b/tests/test_message.py @@ -10,7 +10,7 @@ =20 import time import datetime -from patchewtest import PatchewTestCase, main +from tests.patchewtest import PatchewTestCase, main =20 class ProjectTest(PatchewTestCase): =20 diff --git a/tests/test_model.py b/tests/test_model.py index 30cb409..1464df2 100755 --- a/tests/test_model.py +++ b/tests/test_model.py @@ -8,7 +8,7 @@ # This work is licensed under the MIT License. Please see the LICENSE fil= e or # http://opensource.org/licenses/MIT. =20 -from patchewtest import PatchewTestCase, main +from tests.patchewtest import PatchewTestCase, main from api.models import Message =20 class ImportTest(PatchewTestCase): diff --git a/tests/test_project.py b/tests/test_project.py index eb06050..fbc1f0e 100755 --- a/tests/test_project.py +++ b/tests/test_project.py @@ -8,7 +8,7 @@ # This work is licensed under the MIT License. Please see the LICENSE fil= e or # http://opensource.org/licenses/MIT. =20 -from patchewtest import PatchewTestCase, main +from tests.patchewtest import PatchewTestCase, main =20 class ProjectTest(PatchewTestCase): =20 diff --git a/tests/test_rest.py b/tests/test_rest.py index fa10921..980d61a 100755 --- a/tests/test_rest.py +++ b/tests/test_rest.py @@ -16,7 +16,7 @@ import unittest from django.contrib.auth.models import User =20 sys.path.append(os.path.dirname(__file__)) -from patchewtest import PatchewTestCase, main +from tests.patchewtest import PatchewTestCase, main from api.models import Message from api.rest import AddressSerializer from collections import OrderedDict diff --git a/tests/test_tags.py b/tests/test_tags.py index 8469c42..6c162de 100755 --- a/tests/test_tags.py +++ b/tests/test_tags.py @@ -11,7 +11,7 @@ import sys import os sys.path.append(os.path.dirname(__file__)) -from patchewtest import PatchewTestCase, main +from tests.patchewtest import PatchewTestCase, main =20 class ImportTest(PatchewTestCase): =20 diff --git a/tests/test_testing.py b/tests/test_testing.py index 8f831a1..989ccd1 100755 --- a/tests/test_testing.py +++ b/tests/test_testing.py @@ -13,7 +13,7 @@ import sys import os import subprocess sys.path.append(os.path.dirname(__file__)) -from patchewtest import PatchewTestCase, main +from tests.patchewtest import PatchewTestCase, main from api.models import Message =20 def create_test(project, name): --=20 2.17.1 _______________________________________________ Patchew-devel mailing list Patchew-devel@redhat.com https://www.redhat.com/mailman/listinfo/patchew-devel