https://github.com/demirantay/pytento
🍵 statically-typed testing framework written for python
https://github.com/demirantay/pytento
command-line-tool testing tool
Last synced: 3 months ago
JSON representation
🍵 statically-typed testing framework written for python
- Host: GitHub
- URL: https://github.com/demirantay/pytento
- Owner: demirantay
- License: mit
- Created: 2021-08-20T13:14:03.000Z (almost 5 years ago)
- Default Branch: main
- Last Pushed: 2021-10-01T07:10:16.000Z (over 4 years ago)
- Last Synced: 2025-12-15T21:46:37.323Z (7 months ago)
- Topics: command-line-tool, testing, tool
- Language: Python
- Homepage:
- Size: 39.1 KB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# Pytento
Pytento is a lightweight and staticly-typed testing framework written for python. It is not designed or coded to be used for production level projects. I just coded this project in order to understand more about testing in general and packaging python projects. However, still it is a micro-testing framework and it works! So you can use it anywhere if you would like to!
## Installing
Install and update using pip:
```
$ pip install pytento
```
## A Simple Example
```python
# filename.py
from pytento.case import TestCase
from pytento.core import Pytento
class TestFoo(TestCase):
def test_equality(self):
a = 1
b = 1
return self.assertEqual(a, b)
class TestBar(TestCase):
def test_unequality(self):
a = 1
b = 2
return self.assertNotEqual(a, b)
new_test = TestFoo()
new_test2 = TestBar()
pytento = Pytento(new_test, new_test2)
pytento.test_runner()
pytento.output()
```
```
$ python filename.py
```
## Quick Docs
As you can see above you can test your datas with the `assert*` keyword. Down below you can find
- `assertEqual(a, b)` -- returns true if a and b have the same value
- `assertNotEqual(a, b)` -- returns true if a and b do not have the same value
- `assertTrue(a)` -- returns true if a is true
- `assertFalse(a)` -- returns false if a is false
- `assertIs(a, b)` -- returns true if a is b
- `assertIsNot(a, b)` -- returns true if a is not b
- `assertIsNone(a)` -- returns true if a is none
- `assertIsNotNone(a)` -- returns true if is not none
- `assertIsIn(a, b)` -- returns true if a is in b
## Links
- Documentation: https://github.com/demirantay/pytento/blob/main/docs/index.md
- Changes: https://github.com/demirantay/pytento/blob/main/docs/changes_log.md
- PyPI Releases: https://pypi.org/project/pytento/
- Source Code: https://github.com/demirantay/pytento/
- Issue Tracker: https://github.com/demirantay/pytento/issues/