From nobody Sun Jul 28 23:57:48 2024 X-Original-To: dev-commits-ports-main@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WXJMd69P8z5Rxl9; Sun, 28 Jul 2024 23:57:49 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "mxrelay.nyi.freebsd.org", Issuer "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WXJMd082pz4ff5; Sun, 28 Jul 2024 23:57:49 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1722211069; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=VE/i5pU/wiiSjK6/2qx7fgMX7rAhItIG9XJ+LOPnCZM=; b=ZutSTMgpIpcHSAXCJIsX/wzlEml1S0NYitKZP+rQlJsTlr58OeEoNtCBqCIJtsV4xa9afW 47bgyhHKPCcvi2EQzQP5OIWdqIuZx+SMMm5G4x9l2iC8h+xCYvR8b7OsgO/Jh8KzV8bILd FbWl0zGsaeu9j7TBaVd4a00Ccb3xsiXpw3aLq3aF5YRlSeK7fzQE2tddGAAiZmlMRiKVYn PrrH50ocmfX735LfofrQFlMGnkzdzubNhRGtxTHAZpRRMzto4F960kYK9CsUyZXBjuIx+c J7c5Qwg24/NEtwqzrC6trvJXkUiWnBB8HWYfGQBjAsxHDkuPbVZpzzGFncMm7Q== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1722211069; a=rsa-sha256; cv=none; b=o88+7jfawbB/L2FAtcE2z21/OCYVbLevN9OJDHULvc0fkJ9fdPk6Y4C84VxUB4jWv4mCO8 Yk8uL0C1t4mGhFkQEpS7Huhx44dzxfFBgHMxpoXtqumYtgp19bP4tkyovbcmWKszi7SCjO WR42zm/fUMmawzURt3n1/vruzoqyBNysUMnW8WKKT8uVjQqXC1KfL/G4xfqgc9UnLXxHMi iMExQtALjpOXmJBIivp5O5yy6Zb1hvHNjY8JG0ybB0pe1IzWRUqChyDVRBam49YTSMj0nr kcyb9MpIHuSjBOnejT/All9Qs11qG63BSNR0zkTSTvmGPKPo9h08P1EkAJ3r1w== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1722211069; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=VE/i5pU/wiiSjK6/2qx7fgMX7rAhItIG9XJ+LOPnCZM=; b=qwxqBqcEOVAqHu6G8NWg9+AJgGeb5xWHFE9/BXamkBmmRPxCzieC5XdwzJhAZcCJggqxqg bxI3LOmj4sFRPIxEM1wJqVuSg/7V35WPpNBczflh0Z5cGD0fH+AVERrjSxr+vsPoyUp+jQ AGiiIUHcbakkjoNNj5dvFKoKEkrYIF6cBU9LcljuNX0HvN+wQnARVfoZ6G1zkH9p3nhvVx 8rRYDAoM2GYaBslPpM5olvR+/79xySyg7oWylpXl0XmXcUARy4kjOLNGx0DvpM7pgnZvlO FitdJoSOOqUQF8ZEVl6vyD65zrzfsMNCZlSveZTgVlFhxZd1EstPvS6I9m6VFQ== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WXJMc6WfFz19Vv; Sun, 28 Jul 2024 23:57:48 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 46SNvmVu005370; Sun, 28 Jul 2024 23:57:48 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 46SNvmSG005367; Sun, 28 Jul 2024 23:57:48 GMT (envelope-from git) Date: Sun, 28 Jul 2024 23:57:48 GMT Message-Id: <202407282357.46SNvmSG005367@gitrepo.freebsd.org> To: ports-committers@FreeBSD.org, dev-commits-ports-all@FreeBSD.org, dev-commits-ports-main@FreeBSD.org From: Yuri Victorovich Subject: git: 2ab8dace2117 - main - devel/py-pytest-examples: New port: Py.test plugin for testing examples in docstrings and markdown files List-Id: Commits to the main branch of the FreeBSD ports repository List-Archive: https://lists.freebsd.org/archives/dev-commits-ports-main List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-ports-main@freebsd.org Sender: owner-dev-commits-ports-main@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: yuri X-Git-Repository: ports X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 2ab8dace211756aa2bbc643945d57df079ae6417 Auto-Submitted: auto-generated The branch main has been updated by yuri: URL: https://cgit.FreeBSD.org/ports/commit/?id=2ab8dace211756aa2bbc643945d57df079ae6417 commit 2ab8dace211756aa2bbc643945d57df079ae6417 Author: Yuri Victorovich AuthorDate: 2024-07-28 21:57:28 +0000 Commit: Yuri Victorovich CommitDate: 2024-07-28 23:57:42 +0000 devel/py-pytest-examples: New port: Py.test plugin for testing examples in docstrings and markdown files --- devel/Makefile | 1 + devel/py-pytest-examples/Makefile | 30 ++++++++++++++++++++++++++++++ devel/py-pytest-examples/distinfo | 3 +++ devel/py-pytest-examples/pkg-descr | 9 +++++++++ 4 files changed, 43 insertions(+) diff --git a/devel/Makefile b/devel/Makefile index 63b2df88c82c..8b4aaa47d538 100644 --- a/devel/Makefile +++ b/devel/Makefile @@ -5531,6 +5531,7 @@ SUBDIR += py-pytest-drop-dup-tests SUBDIR += py-pytest-enabler SUBDIR += py-pytest-env + SUBDIR += py-pytest-examples SUBDIR += py-pytest-factoryboy SUBDIR += py-pytest-fixture-config SUBDIR += py-pytest-flake8 diff --git a/devel/py-pytest-examples/Makefile b/devel/py-pytest-examples/Makefile new file mode 100644 index 000000000000..2223b075fce5 --- /dev/null +++ b/devel/py-pytest-examples/Makefile @@ -0,0 +1,30 @@ +PORTNAME= pytest-examples +DISTVERSION= 0.0.12 +CATEGORIES= devel python +MASTER_SITES= PYPI +PKGNAMEPREFIX= ${PYTHON_PKGNAMEPREFIX} +DISTNAME= ${PORTNAME:S/-/_/}-${DISTVERSION} + +MAINTAINER= yuri@FreeBSD.org +COMMENT= Py.test plugin for testing examples in docstrings and markdown files +WWW= https://github.com/pydantic/pytest-examples + +LICENSE= MIT +LICENSE_FILE= ${WRKSRC}/LICENSE + +BUILD_DEPENDS= ${PYTHON_PKGNAMEPREFIX}hatchling>0:devel/py-hatchling@${PY_FLAVOR} +RUN_DEPENDS= ${PYTHON_PKGNAMEPREFIX}black>=23:devel/py-black@${PY_FLAVOR} \ + ${PYTHON_PKGNAMEPREFIX}pytest>=7:devel/py-pytest@${PY_FLAVOR} \ + ${PYTHON_PKGNAMEPREFIX}ruff>=0.5.0:devel/py-ruff@${PY_FLAVOR} +TEST_DEPENDS= ${PYTHON_PKGNAMEPREFIX}coverage>=0:devel/py-coverage@${PY_FLAVOR} \ + ${PYTHON_PKGNAMEPREFIX}pytest-pretty>0:devel/py-pytest-pretty@${PY_FLAVOR} \ + ${PYTHON_PKGNAMEPREFIX}ruff>=0.5.0:devel/py-ruff@${PY_FLAVOR} + +USES= python +USE_PYTHON= pep517 autoplist pytest + +TEST_ENV= ${MAKE_ENV} PYTHONPATH=${STAGEDIR}${PYTHONPREFIX_SITELIBDIR} + +NO_ARCH= yes + +.include diff --git a/devel/py-pytest-examples/distinfo b/devel/py-pytest-examples/distinfo new file mode 100644 index 000000000000..71107ace10c7 --- /dev/null +++ b/devel/py-pytest-examples/distinfo @@ -0,0 +1,3 @@ +TIMESTAMP = 1722196231 +SHA256 (pytest_examples-0.0.12.tar.gz) = 58da3a1d4d6b5efedbb1c0e4fc94472e44c6bb3e1e199822728d778d809c8ff7 +SIZE (pytest_examples-0.0.12.tar.gz) = 20429 diff --git a/devel/py-pytest-examples/pkg-descr b/devel/py-pytest-examples/pkg-descr new file mode 100644 index 000000000000..77b674a1881c --- /dev/null +++ b/devel/py-pytest-examples/pkg-descr @@ -0,0 +1,9 @@ +Pytest plugin for testing Python code examples in docstrings and markdown files. + +pytest-examples can: +* lint code examples using ruff and black +* run code examples +* run code examples and check print statements are inlined correctly in the code + +It can also update code examples in place to format them and insert or update +print statements.