Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/pzl/py_unitstyle
mocha-style test output for python's unittest module.
https://github.com/pzl/py_unitstyle
python python-unittest test-runner
Last synced: 7 days ago
JSON representation
mocha-style test output for python's unittest module.
- Host: GitHub
- URL: https://github.com/pzl/py_unitstyle
- Owner: pzl
- License: mit
- Created: 2016-04-30T18:06:36.000Z (over 8 years ago)
- Default Branch: master
- Last Pushed: 2017-12-19T03:51:41.000Z (almost 7 years ago)
- Last Synced: 2024-08-10T07:53:06.767Z (3 months ago)
- Topics: python, python-unittest, test-runner
- Language: Python
- Homepage:
- Size: 19.5 KB
- Stars: 1
- Watchers: 2
- Forks: 0
- Open Issues: 1
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
unitstyle
=========`unitstyle` is a python module that adds several output format options for Python's standard `unittest` library (unittest2). Specifically, it adds many of the output options offered by [mocha](https://mochajs.org/#reporters), a javascript unit testing framework. This package was created to port those outputs to Python.
Installation
------------`unitstyle` is available on PyPI. You should be able to install it with `pip install unitstyle`.
Usage
-----
The `unitstyle` package provides itself as a `unittest` TestRunner, and should be used as such.simple example:
```python
import unittest
import unitstylesuite = unittest.TestLoader().discover()
unitstyle.TestRunner().run(suite)```
Supported arguments to `unitstyle`'s TestRunner are:
Output Formats
--------------
- [list](https://mochajs.org/#list)
- [dots](https://mochajs.org/#dot-matrix)
- [jsstream](https://mochajs.org/#json-stream) - a JSON stream
- [JSON](https://mochajs.org/#json)
- [progress](https://mochajs.org/#progress) (bar)
- [min](https://mochajs.org/#min)
- [tap](https://mochajs.org/#tap) - the [Test Anything Protocol](http://en.wikipedia.org/wiki/Test_Anything_Protocol)
- [spec](https://mochajs.org/#spec)Feel free to open an issue to request more, or pull requests!
License
-------
This project and code is licensed under the MIT License. See the `LICENSE` file for more.Copyright (c) 2015 Dan Panzarella