Skip to main content

A simple, pythonic Python test framework

Project description

lightestlib

A simple, pythonic Python test framework implemented in Python.

Overview

lightestlib is a lightweight testing framework designed for simplicity and ease of use. It provides a flexible architecture that allows you to define different types of tests and customize output formatting and reporting.

Quick Start

Installation

Install from PyPI:

pip install lightestlib

Or clone the repository:

git clone <repository-url>
cd testlib

Hence using the match-case sentences, only python 3.10 and above are supported

Basic Usage

from testlib.suites import PlainTestsuite
from testlib.outputers import StdOutputer
from testlib.formatters import StdMessageFormatter

# Create a test suite
suite = PlainTestsuite()
suite.add_outputer(StdOutputer(), StdMessageFormatter("normal"))

# Add a plain test
@suite.add["plain"]
def sample_test():
    print("Hello, pytestlib!")
    return True

# Run the tests
suite.run()

Features

  • Multiple test types: Plain, Result, Exception, and Output tests
  • Flexible output system with support for console and file output
  • Customizable message formatting
  • Extensible architecture for adding new test types

Documentation

For detailed usage instructions, please see the documentation in the docs/ directory:

  • User Guide
  • API Reference
  • Examples

License

See the LICENSE file for details.

Contact

For bug reports and feature requests, please use the issue tracker. For general questions and discussions, please use GitHub Discussions.

Project details


Release history Release notifications | RSS feed

This version

0.1

Download files

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

Source Distribution

lightestlib-0.1.tar.gz (30.7 kB view details)

Uploaded Source

Built Distribution

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

lightestlib-0.1-py3-none-any.whl (35.7 kB view details)

Uploaded Python 3

File details

Details for the file lightestlib-0.1.tar.gz.

File metadata

  • Download URL: lightestlib-0.1.tar.gz
  • Upload date:
  • Size: 30.7 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.11.9

File hashes

Hashes for lightestlib-0.1.tar.gz
Algorithm Hash digest
SHA256 3f11260924cf15ae35f81244284ed867b2bb815009dea563b63587e12e41c640
MD5 fc3d0c208e7a2a0e67e132db7c171af5
BLAKE2b-256 b178fe5c0d12730f46ca13a528fba2aad1ac770d9b6702d5e0c6ab57a0b4ff4e

See more details on using hashes here.

File details

Details for the file lightestlib-0.1-py3-none-any.whl.

File metadata

  • Download URL: lightestlib-0.1-py3-none-any.whl
  • Upload date:
  • Size: 35.7 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.11.9

File hashes

Hashes for lightestlib-0.1-py3-none-any.whl
Algorithm Hash digest
SHA256 58d046bd860971f4f2d475813836ca9cc5cbfdcc6b842137d06b440cecb44f08
MD5 3f812d27e4117ab9ce80a1343997dd83
BLAKE2b-256 0d4e75a2679bb06526a9ad69a45a742c11e0970864647417a9d60b2db98ab56e

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