Metadata-Version: 2.1
Name: py-loop
Version: 0.2.1
Summary: Run commands until it fails
Home-page: https://github.com/jeremad/looper
Author: Kontrol SAS
License: UNKNOWN
Platform: UNKNOWN
Classifier: Programming Language :: Python :: 3.6
Classifier: Programming Language :: Python :: 3.7
Requires-Python: >=3.6
Requires-Dist: cli-ui
Provides-Extra: dev
Requires-Dist: black ; extra == 'dev'
Requires-Dist: codacy-coverage ; extra == 'dev'
Requires-Dist: codecov ; extra == 'dev'
Requires-Dist: flake8 ; extra == 'dev'
Requires-Dist: mypy ; extra == 'dev'
Requires-Dist: pytest ; extra == 'dev'
Requires-Dist: pytest-cov ; extra == 'dev'

[![Codacy Badge](https://api.codacy.com/project/badge/Grade/9c0df6535cb64f03921f3c9bb76c9fba)](https://app.codacy.com/app/jeremad/looper?utm_source=github.com&utm_medium=referral&utm_content=jeremad/looper&utm_campaign=Badge_Grade_Dashboard)
[![License](https://img.shields.io/github/license/jeremad/looper.svg)](https://opensource.org/licenses/MIT)
[![Build](https://img.shields.io/travis/jeremad/looper/master.svg)](https://travis-ci.org/jeremad/looper)
[![codecov](https://codecov.io/gh/jeremad/looper/branch/master/graph/badge.svg)](https://codecov.io/gh/jeremad/looper)

# Basic tool to run commands in loop

This tool was intended to help QA guy like me with flaky tests, buy either measuring the "flakyness" of the test, or run it until it fails to debug it.

## Usage

Let's say your test command is `run test`

### Debug

You want to run a test until it fails to debug it, and you know it may take a while:
`$ looper --max-tries 0 --stop-on-first-fail "run test"`

`max-tries` to 0, means that there is no limit to the number of times a test can sucessfully run

### Measure

You want to find the failing rate of a test of out 1000 runs:
`$ looper --max-tries 1000 "run test"`

At the end you will have a sumary

## Installation

`pip install --user py-loop`


