# Punic
Punic is a lightweight and user-friendly unit testing framework for Python. It provides an easy and efficient way to write and execute tests for your Python code.
## Features
- **Easy Integration:** Punic can be easily integrated into your Python projects.
- **Simple Assertion:** The framework provides an `assert_` method for making assertions on expected and actual values.
- **Output Formatting:** Test results are displayed in a clear and readable format.
- **Customizable:** Punic is flexible and customizable to suit your specific requirements.
## Getting Started
1. Install Punic: `pip install punictest`
2. Write your tests using the `assert_` method:
```python
from punic import Punic
p = Punic()
p.assert_(4, lambda: 2 + 2, "Addition")
```
3. Run your test program.
## Reference
The Punic class provides methods for defining and executing tests, configuring behavior, and callbacks:
`assert_(assertion, function, named="Unnamed")`: Defines a test case.
`exit_on_failure(on_exit)`: Configures whether the program should exit on a test failure.
`when_failed(action)`: Sets a callback function to be executed when a test case fails.
`when_passed(action)`: Sets a callback function to be executed when a test case passes.
## Contributions
Contributions to Punic are welcome! Please open an issue or submit a pull request for bug fixes, new features, or enhancements.
## License
Punic is released under the MIT License. See the LICENSE file for more details.
Raw data
{
"_id": null,
"home_page": "https://github.com/Somespi/Punic",
"name": "punictest",
"maintainer": "",
"docs_url": null,
"requires_python": "",
"maintainer_email": "",
"keywords": "unit testing test automation quality assurance software development",
"author": "Someone.",
"author_email": "someonegithub@email.com",
"download_url": "https://files.pythonhosted.org/packages/30/68/14a2fcbcb30b97e198481244ea375e02514131866adf7aa7b69fd4fbc7f3/punictest-0.1.1.tar.gz",
"platform": null,
"description": "# Punic\r\n\r\nPunic is a lightweight and user-friendly unit testing framework for Python. It provides an easy and efficient way to write and execute tests for your Python code.\r\n\r\n## Features\r\n\r\n- **Easy Integration:** Punic can be easily integrated into your Python projects.\r\n\r\n- **Simple Assertion:** The framework provides an `assert_` method for making assertions on expected and actual values.\r\n\r\n- **Output Formatting:** Test results are displayed in a clear and readable format.\r\n\r\n- **Customizable:** Punic is flexible and customizable to suit your specific requirements.\r\n\r\n## Getting Started\r\n\r\n1. Install Punic: `pip install punictest`\r\n\r\n2. Write your tests using the `assert_` method:\r\n\r\n```python\r\nfrom punic import Punic\r\n\r\np = Punic()\r\np.assert_(4, lambda: 2 + 2, \"Addition\")\r\n\r\n``` \r\n\r\n3. Run your test program.\r\n\r\n\r\n## Reference\r\n\r\nThe Punic class provides methods for defining and executing tests, configuring behavior, and callbacks:\r\n\r\n`assert_(assertion, function, named=\"Unnamed\")`: Defines a test case.\r\n\r\n`exit_on_failure(on_exit)`: Configures whether the program should exit on a test failure.\r\n\r\n`when_failed(action)`: Sets a callback function to be executed when a test case fails.\r\n\r\n`when_passed(action)`: Sets a callback function to be executed when a test case passes.\r\n\r\n## Contributions\r\nContributions to Punic are welcome! Please open an issue or submit a pull request for bug fixes, new features, or enhancements.\r\n\r\n## License\r\nPunic is released under the MIT License. See the LICENSE file for more details.\r\n",
"bugtrack_url": null,
"license": "",
"summary": "Simple unit testing for python",
"version": "0.1.1",
"project_urls": {
"Homepage": "https://github.com/Somespi/Punic"
},
"split_keywords": [
"unit",
"testing",
"test",
"automation",
"quality",
"assurance",
"software",
"development"
],
"urls": [
{
"comment_text": "",
"digests": {
"blake2b_256": "0a32e1dc4f04552ad5cceb38b911a6c0d416a0ee5ee13390fc1c7723e8a852c6",
"md5": "2fe0daa82eb30c167b99d9ca04a3dfe3",
"sha256": "4c1b06f9ed56ae8d5eab308c37a04221b4e8c48d1e3a19908cb128a2a4b97a45"
},
"downloads": -1,
"filename": "punictest-0.1.1-py3-none-any.whl",
"has_sig": false,
"md5_digest": "2fe0daa82eb30c167b99d9ca04a3dfe3",
"packagetype": "bdist_wheel",
"python_version": "py3",
"requires_python": null,
"size": 3574,
"upload_time": "2023-07-06T22:24:20",
"upload_time_iso_8601": "2023-07-06T22:24:20.528841Z",
"url": "https://files.pythonhosted.org/packages/0a/32/e1dc4f04552ad5cceb38b911a6c0d416a0ee5ee13390fc1c7723e8a852c6/punictest-0.1.1-py3-none-any.whl",
"yanked": false,
"yanked_reason": null
},
{
"comment_text": "",
"digests": {
"blake2b_256": "306814a2fcbcb30b97e198481244ea375e02514131866adf7aa7b69fd4fbc7f3",
"md5": "655cdc441a7b5cbb86d22037c5cd3dc3",
"sha256": "0706b413091ae80dd29cde40738a297e729163effb23669ae0418b2a015e17a1"
},
"downloads": -1,
"filename": "punictest-0.1.1.tar.gz",
"has_sig": false,
"md5_digest": "655cdc441a7b5cbb86d22037c5cd3dc3",
"packagetype": "sdist",
"python_version": "source",
"requires_python": null,
"size": 3211,
"upload_time": "2023-07-06T22:24:22",
"upload_time_iso_8601": "2023-07-06T22:24:22.765756Z",
"url": "https://files.pythonhosted.org/packages/30/68/14a2fcbcb30b97e198481244ea375e02514131866adf7aa7b69fd4fbc7f3/punictest-0.1.1.tar.gz",
"yanked": false,
"yanked_reason": null
}
],
"upload_time": "2023-07-06 22:24:22",
"github": true,
"gitlab": false,
"bitbucket": false,
"codeberg": false,
"github_user": "Somespi",
"github_project": "Punic",
"travis_ci": false,
"coveralls": false,
"github_actions": false,
"lcname": "punictest"
}