From patchwork Fri Nov 16 03:57:32 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Ricardo Martincoski X-Patchwork-Id: 998743 Return-Path: X-Original-To: incoming-buildroot@patchwork.ozlabs.org Delivered-To: patchwork-incoming-buildroot@bilbo.ozlabs.org Authentication-Results: ozlabs.org; spf=pass (mailfrom) smtp.mailfrom=busybox.net (client-ip=140.211.166.133; helo=hemlock.osuosl.org; envelope-from=buildroot-bounces@busybox.net; receiver=) Authentication-Results: ozlabs.org; dmarc=fail (p=none dis=none) header.from=gmail.com Authentication-Results: ozlabs.org; dkim=fail reason="signature verification failed" (2048-bit key; unprotected) header.d=gmail.com header.i=@gmail.com header.b="qy4DVr/n"; dkim-atps=neutral Received: from hemlock.osuosl.org (smtp2.osuosl.org [140.211.166.133]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ozlabs.org (Postfix) with ESMTPS id 42x4HQ4l9zz9s0t for ; Fri, 16 Nov 2018 14:59:30 +1100 (AEDT) Received: from localhost (localhost [127.0.0.1]) by hemlock.osuosl.org (Postfix) with ESMTP id AE091889EC; Fri, 16 Nov 2018 03:59:27 +0000 (UTC) X-Virus-Scanned: amavisd-new at osuosl.org X-Amavis-Alert: BAD HEADER SECTION, Duplicate header field: "References" Received: from hemlock.osuosl.org ([127.0.0.1]) by localhost (.osuosl.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id Nd5jkJ8Ztly1; Fri, 16 Nov 2018 03:59:27 +0000 (UTC) Received: from ash.osuosl.org (ash.osuosl.org [140.211.166.34]) by hemlock.osuosl.org (Postfix) with ESMTP id 2328C889D0; Fri, 16 Nov 2018 03:59:27 +0000 (UTC) X-Original-To: buildroot@lists.busybox.net Delivered-To: buildroot@osuosl.org Received: from silver.osuosl.org (smtp3.osuosl.org [140.211.166.136]) by ash.osuosl.org (Postfix) with ESMTP id 53EC91BF2EE for ; Fri, 16 Nov 2018 03:59:25 +0000 (UTC) Received: from localhost (localhost [127.0.0.1]) by silver.osuosl.org (Postfix) with ESMTP id 515C230940 for ; Fri, 16 Nov 2018 03:59:25 +0000 (UTC) X-Virus-Scanned: amavisd-new at osuosl.org X-Amavis-Alert: BAD HEADER SECTION, Duplicate header field: "References" Received: from silver.osuosl.org ([127.0.0.1]) by localhost (.osuosl.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id tQV3a-uPcuKC for ; Fri, 16 Nov 2018 03:59:24 +0000 (UTC) X-Greylist: domain auto-whitelisted by SQLgrey-1.7.6 Received: from mail-qk1-f182.google.com (mail-qk1-f182.google.com [209.85.222.182]) by silver.osuosl.org (Postfix) with ESMTPS id C2B34227A9 for ; Fri, 16 Nov 2018 03:59:24 +0000 (UTC) Received: by mail-qk1-f182.google.com with SMTP id y16so35467043qki.7 for ; Thu, 15 Nov 2018 19:59:24 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:to:cc:subject:date:message-id:in-reply-to:references :in-reply-to:references; bh=l6kM5rzJVFvGjT3iIxlwHw8v1s334N7iYst9FXDgYe0=; b=qy4DVr/nRtkvWqmfnT63H0TwNdpoLe2667Wb6oDDmdAhfKKPgjvTxc8+JWVskeInjW p+2rZ74FMgmsYRzuY+h7qRNzT2im6+H8yvBaakhUVxiXUVWRK+sGnMc+ThON3GupDD9T iP7mm27KsXfZp1UgFQKS4hkP+q5m37TK3gXVPD0evs7QQw2+LkyBsPGvjmqTO6wmn+5u SFh4JJfTCbZ2EKIU1yVCl1TthsIflM50HIxxrKRzaHb07Re/A+TTLp/fXDClI9TVU0+x oTdwk5qvuBOmnukNivbQwPptnZE6+K9hziU2q5GJeUxpUByrttHzGVzHVqCbuEFFdcCz 1Ngw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:in-reply-to:references; bh=l6kM5rzJVFvGjT3iIxlwHw8v1s334N7iYst9FXDgYe0=; b=Aj78BPiGllcg7RGFgYGR61r+I6E+yupf3Fnyug7F8TRSR0PxRXVgn/P9XHXiT1PuHd ksNMFAffc5oz6idF9OrgJKFW+rrJJRUKhlsoOmMeyOOZJGmTUEVCVOqlTewmzsZpowpy c0nLOhrXHWslfocPNraUTUdH1gXz6VFbNFxll8k3mI6ANKmVFrCTMllrOUcNyZgUP01X uX7lzHH/8DkNSw6mYe3qKrJgmpaX3129WHQzDf9DS0/UDw7yKE1ZYTbiEl4GWMt036pA KYjZDiz1bkczKusvRbc/iiiyjlKJrP6zz6ZCNIccARSYQ2G7IznfR6ews9TnbtHE3LhT 0WeQ== X-Gm-Message-State: AGRZ1gKRxm2dn5xF4TqxmertmIX9norUBSTCJOdRs1/5k6re4Uo2n13M ubv2rZ1HxUftOq2hn/1mtDvYEOhmw3o= X-Google-Smtp-Source: AJdET5dNxQuyZP9nJpUT3++ul34ZhUYa20pMoM1GykMvrrc8xpMkKnsXHLl/phe58Gi2lp8zdZescA== X-Received: by 2002:ac8:1102:: with SMTP id c2mr8680013qtj.195.1542340763732; Thu, 15 Nov 2018 19:59:23 -0800 (PST) Received: from ultri5.home ([177.132.215.168]) by smtp.gmail.com with ESMTPSA id a17sm13921641qth.93.2018.11.15.19.59.21 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Thu, 15 Nov 2018 19:59:23 -0800 (PST) From: Ricardo Martincoski To: buildroot@buildroot.org Date: Fri, 16 Nov 2018 01:57:32 -0200 Message-Id: <20181116035735.31507-13-ricardo.martincoski@gmail.com> X-Mailer: git-send-email 2.17.1 In-Reply-To: <20181116035735.31507-1-ricardo.martincoski@gmail.com> References: <20181116035735.31507-1-ricardo.martincoski@gmail.com> In-Reply-To: <20180926025514.2092-1-ricardo.martincoski@gmail.com> References: <20180926025514.2092-1-ricardo.martincoski@gmail.com> Subject: [Buildroot] [next 12/15] support/testing: add python-service-identity tests X-BeenThere: buildroot@busybox.net X-Mailman-Version: 2.1.29 Precedence: list List-Id: Discussion and development of buildroot List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Ricardo Martincoski MIME-Version: 1.0 Errors-To: buildroot-bounces@busybox.net Sender: "buildroot" Add a simple test case that imports the module. Signed-off-by: Ricardo Martincoski --- .gitlab-ci.yml | 2 ++ .../package/sample_python_service_identity.py | 2 ++ .../package/test_python_service_identity.py | 23 +++++++++++++++++++ 3 files changed, 27 insertions(+) create mode 100644 support/testing/tests/package/sample_python_service_identity.py create mode 100644 support/testing/tests/package/test_python_service_identity.py diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml index a0659d6bfb..4166412df3 100644 --- a/.gitlab-ci.yml +++ b/.gitlab-ci.yml @@ -345,6 +345,8 @@ tests.package.test_python_pynacl.TestPythonPy2Pynacl: *runtime_test tests.package.test_python_pynacl.TestPythonPy3Pynacl: *runtime_test tests.package.test_python_pyyaml.TestPythonPy2Pyyaml: *runtime_test tests.package.test_python_pyyaml.TestPythonPy3Pyyaml: *runtime_test +tests.package.test_python_service_identity.TestPythonPy2ServiceIdentity: *runtime_test +tests.package.test_python_service_identity.TestPythonPy3ServiceIdentity: *runtime_test tests.package.test_python_twisted.TestPythonPy2Twisted: *runtime_test tests.package.test_python_twisted.TestPythonPy3Twisted: *runtime_test tests.package.test_python_txaio.TestPythonPy2Txaio: *runtime_test diff --git a/support/testing/tests/package/sample_python_service_identity.py b/support/testing/tests/package/sample_python_service_identity.py new file mode 100644 index 0000000000..3184b6c580 --- /dev/null +++ b/support/testing/tests/package/sample_python_service_identity.py @@ -0,0 +1,2 @@ +from service_identity import VerificationError # noqa +from service_identity.pyopenssl import verify_hostname # noqa diff --git a/support/testing/tests/package/test_python_service_identity.py b/support/testing/tests/package/test_python_service_identity.py new file mode 100644 index 0000000000..6aeb77de8c --- /dev/null +++ b/support/testing/tests/package/test_python_service_identity.py @@ -0,0 +1,23 @@ +from tests.package.test_python import TestPythonPackageBase + + +class TestPythonPy2ServiceIdentity(TestPythonPackageBase): + __test__ = True + config = TestPythonPackageBase.config + \ + """ + BR2_PACKAGE_PYTHON=y + BR2_PACKAGE_PYTHON_SERVICE_IDENTITY=y + """ + sample_scripts = ["tests/package/sample_python_service_identity.py"] + timeout = 30 + + +class TestPythonPy3ServiceIdentity(TestPythonPackageBase): + __test__ = True + config = TestPythonPackageBase.config + \ + """ + BR2_PACKAGE_PYTHON3=y + BR2_PACKAGE_PYTHON_SERVICE_IDENTITY=y + """ + sample_scripts = ["tests/package/sample_python_service_identity.py"] + timeout = 30