Skip to main content

P Test Platform Tools Base Lib

Project description

ptools-base

P Test Platform Tools Base Lib

How to install

pip install -U ptools-base

How to write assert

from ptools_base.tool import write_asserts
from ptools_base.schema import AssertSchema, AssertSchemaResultEnum

write_asserts(
    [
        AssertSchema(
            result=AssertSchemaResultEnum.SUCCESS,
            content="your assert content"
        ),
        AssertSchema(
            result=AssertSchemaResultEnum.FAILED,
            content="your assert content"
        ),
        AssertSchema(
            result=AssertSchemaResultEnum.SKIPPED,
            content="your assert content"
        )
    ]
)

How to copy extra data

from ptools_base.tool import copy_2_extra

# copy file to extra
file_path = "your file path"
copy_2_extra(file_path)

# copy dir to extra
dir_path = "your dir path"
copy_2_extra(dir_path)

How to write env

from ptools_base.schema import EnvSchema
from ptools_base.tool import write_envs

write_envs([EnvSchema(key="your env key", value="your env value")])

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

ptools_base-1.1.2.tar.gz (3.8 kB view details)

Uploaded Source

Built Distribution

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

ptools_base-1.1.2-py3-none-any.whl (3.3 kB view details)

Uploaded Python 3

File details

Details for the file ptools_base-1.1.2.tar.gz.

File metadata

  • Download URL: ptools_base-1.1.2.tar.gz
  • Upload date:
  • Size: 3.8 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.0.1 CPython/3.8.10

File hashes

Hashes for ptools_base-1.1.2.tar.gz
Algorithm Hash digest
SHA256 4a143ed1c4e0c6be3ead9074d9d8bbd1194b94f83b130d2a6da3f3574fd30d27
MD5 1dd790a121b7cc4a3d8fe837d673223f
BLAKE2b-256 f0699280c5f8fe456cffe083b710fd1017615cae29eb7d6cf67680003df7d1a4

See more details on using hashes here.

File details

Details for the file ptools_base-1.1.2-py3-none-any.whl.

File metadata

  • Download URL: ptools_base-1.1.2-py3-none-any.whl
  • Upload date:
  • Size: 3.3 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.0.1 CPython/3.8.10

File hashes

Hashes for ptools_base-1.1.2-py3-none-any.whl
Algorithm Hash digest
SHA256 628551df52c5a20eb280ed7b842c833a4ea8b9e51197a85314371c797072b048
MD5 1e95f0fdb78fc7c298d2fc76d57d3593
BLAKE2b-256 afe484f26b75bd99ed8e70a2800dd4505072026e7612391bb425638f667fa096

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