Skip to main content

Test Anything Protocol producer API for Python.

Project description

Producer for Test Anything Protocol output in Python. Automatically counts test points at call time for TAP version 12, 13, and 14.

from tap_producer import TAP
with TAP() as t:
  t.ok('passed')
  t.ok('also passed')

TAP version 12 supports plan, ok, not ok, diagnostic comment, and bail out functionality.

from tap_producer import TAP
with TAP() as t:
   t.ok('passed').comment('debug information')
   if FAIL_CONDITION:
      t.not_ok('did not pass')
      t.bail_out()

TAP version 13 supports the aforementioned as well as subtest context manager and YAML diagnostic output.

with TAP.subtest('subtest') as st:
   st.plan(count=1, skip_count=0).ok('ok', {'yaml-key': 'yaml-val'})

TAP-Producer also includes two decorators, a suppress context manager for suppressing TAP output and a strict context manager for raising not ok test cases to Python errors.

from tap_producer import TAP
with TAP() as t:
   with t.suppress():
      t.ok('passed but suppressed')
   with t.strict()
      t.not_ok('this is now a Python exception')

License

Licensed Apache-2.0 WITH LLVM-exception, no NOTICE file needed if you want to vendor TAP-Producer into your project, see LICENSE.txt for more information.

https://raw.githubusercontent.com/sigstore/community/main/artwork/badge/sigstore_codesigned_purple.png

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

TAP-Producer-1.3.3.tar.gz (29.9 kB view details)

Uploaded Source

Built Distributions

If you're not sure about the file name format, learn more about wheel file names.

TAP_Producer-1.3.3-cp313-none-any.whl (21.2 kB view details)

Uploaded CPython 3.13

TAP_Producer-1.3.3-cp312-none-any.whl (21.2 kB view details)

Uploaded CPython 3.12

TAP_Producer-1.3.3-cp311-none-any.whl (21.9 kB view details)

Uploaded CPython 3.11

TAP_Producer-1.3.3-cp310-none-any.whl (17.3 kB view details)

Uploaded CPython 3.10

File details

Details for the file TAP-Producer-1.3.3.tar.gz.

File metadata

  • Download URL: TAP-Producer-1.3.3.tar.gz
  • Upload date:
  • Size: 29.9 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/5.1.1 CPython/3.12.7

File hashes

Hashes for TAP-Producer-1.3.3.tar.gz
Algorithm Hash digest
SHA256 578e41f05a5fccb3e82ac258f1358274acb2dbeaa4b2e0f0dc2e2178e070cbd1
MD5 febb132cd0f1bca883f378acf8a8381e
BLAKE2b-256 6ec0e132959bb9ad7aa1592e467adc878d7f3418fa87b671c87588932fcfff95

See more details on using hashes here.

File details

Details for the file TAP_Producer-1.3.3-cp313-none-any.whl.

File metadata

  • Download URL: TAP_Producer-1.3.3-cp313-none-any.whl
  • Upload date:
  • Size: 21.2 kB
  • Tags: CPython 3.13
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/5.1.1 CPython/3.12.7

File hashes

Hashes for TAP_Producer-1.3.3-cp313-none-any.whl
Algorithm Hash digest
SHA256 6bffad3c4ca2157789ef3813f9f3873f03317aba4832e94929729f569cd8ceb3
MD5 9d529ca7d2b47e70f657546d0334f3c3
BLAKE2b-256 afbdc9d0de03a29edc0f5115c6de2c1d21e11cfd54de7c125f8e2af0333eb601

See more details on using hashes here.

File details

Details for the file TAP_Producer-1.3.3-cp312-none-any.whl.

File metadata

  • Download URL: TAP_Producer-1.3.3-cp312-none-any.whl
  • Upload date:
  • Size: 21.2 kB
  • Tags: CPython 3.12
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/5.1.1 CPython/3.12.7

File hashes

Hashes for TAP_Producer-1.3.3-cp312-none-any.whl
Algorithm Hash digest
SHA256 3c590c195cc1212053d7ff8b3937cb9e6893dc0f096935a2a8f11a783ebbc569
MD5 0ed710a38f345cba76803518c731efe8
BLAKE2b-256 e0595c8c72d6df3a36854d62f9620ebe2a9698dd047216be8f8d827e1f5fedb4

See more details on using hashes here.

File details

Details for the file TAP_Producer-1.3.3-cp311-none-any.whl.

File metadata

  • Download URL: TAP_Producer-1.3.3-cp311-none-any.whl
  • Upload date:
  • Size: 21.9 kB
  • Tags: CPython 3.11
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/5.1.1 CPython/3.12.7

File hashes

Hashes for TAP_Producer-1.3.3-cp311-none-any.whl
Algorithm Hash digest
SHA256 4eda69290643140c9392f0a0edc1c8aed0bdc25065c1031797b049572ad8e4db
MD5 a0e31f3c718ac935c7b88512ef7ff963
BLAKE2b-256 2f4b972d984ef183c2749886a36bceb2250b098a6a75e9276212aaeb08b4fd1a

See more details on using hashes here.

File details

Details for the file TAP_Producer-1.3.3-cp310-none-any.whl.

File metadata

  • Download URL: TAP_Producer-1.3.3-cp310-none-any.whl
  • Upload date:
  • Size: 17.3 kB
  • Tags: CPython 3.10
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/5.1.1 CPython/3.12.7

File hashes

Hashes for TAP_Producer-1.3.3-cp310-none-any.whl
Algorithm Hash digest
SHA256 8bb9da505c05a7f6f0fd49c4fedfad9c512d778f6abb64a4ac5649b18ccb5819
MD5 0f25c1210d7e87cee41c87bc69170868
BLAKE2b-256 6c78ca852fc2ff0126b47818c6f5d8f98cbcc801e5b6d631cb41f06f989ee8f1

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page