GithubHelp home page GithubHelp logo

netantho / crontabber Goto Github PK

View Code? Open in Web Editor NEW

This project forked from mozilla/crontabber

0.0 2.0 0.0 252 KB

A cron job runner with self-healing and job dependencies.

Home Page: http://crontabber.readthedocs.org/

License: Mozilla Public License 2.0

crontabber's Introduction

crontabber

A cron job runner with self-healing and job dependencies.

License: MPL 2

How to run tests

First you need to create a dedicated test database. We recommend you call it test_crontabber. Then you need the necessary credentials for it.

Before running the tests you need to install some extras to be able to run tests at all:

pip install -r test-requirements.txt

Next, in the root directory of the project create a file called test-crontabber.ini and it should look something like this:

[crontabber]
user=myusername
password=mypassword
dbname=test_crontabber

To start all the tests run:

PYTHONPATH=. nosetests

If you want to run a specific test in a specific file in a specific class you can define it per the nosetests standard like this for example:

PYTHONPATH=. nosetests tests crontabber/tests/test_crontabber.py:TestCrontabber.test_basic_run_job

If you want the tests to stop as soon as the first test fails add -x to that same command above.

Also, if you want nosetests to not capture stdout add -s to that same command as above.

How to do code coverage analysis

First you need to install the coverage module. Then, with `nosetests, you can run this:

PYTHONPATH=. nosetests --with-coverage --cover-erase --cover-html --cover-package=crontabber

After it has run, you can open the file cover/index.html in browser.

How to run the exampleapp

The example app helps you set up a playground to play around with and test crontabber to gain a better understanding of how it works.

The best place to start with is to read the exampleapp/README.md file and go through its steps. Once you get the basics to work you can start experimenting with adding your job classes.

crontabber's People

Contributors

peterbe avatar twobraids avatar

Watchers

 avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.