THIS PROJECT IS NOW UNMAINTAINED.
This project has been deprecated when Fedora switched to using Bodhi2 (and respective python-fedora package update), which requires OpenID authentication before performing write operations (submitting comments). Only query operations are currently supported by fake_fedorainfra with Bodhi2. We're trying to get away from submitting Bodhi comments in general, so fixing this library was not deemed worth the time. This project might be revived in the future if new Bodhi2 mocking needs arise or we need to mock other services (e.g. Koji).
A simple webapp which will allow to mock Fedora Bodhi for comment submit requests. Mostly to be used together with libtaskotron.
All Bodhi list (query) operations are forwarded to real Bodhi and the result is passed back. The post comment operation is saved to a local database and not forwarded to the official instance.
If you want to be able to quickly use fake_fedorainfra for development purposes, follow these steps:
$ virtualenv env_fakefedorainfra $ source env_fakefedorainfra/bin/activate $ pip install -r requirements.txt $ DEV=true ./init_db.sh $ DEV=true python runapp.py
The app frontend is running at http://localhost:5000/boji, you can see all
locally stored comments there. The real Bodhi-like interface is running at
http://localhost:5000/bodhi, for example you can try
http://localhost:5000/bodhi/list - that requests a list of most recent
Bodhi updates, and this request should be redirected to the official Fedora
Bodhi instance. Any comment submit requests should be kept inside
fake_fedorainfra, though. All comments are stored inside
You can configure this app by copying
conf/setting.py and adjusting values as you see fit. It overrides default
You might want to use this tool together with libtaskotron. You need to
configure libtaskotron to use fake_fedorainfra instead of real Bodhi. Edit
/etc/taskotron/taskotron.yaml and set the following value:
You might also need to adjust
depending on your local settings.
If you don't have
fas_password filled out, you'll
need to do so (any value).
You can run this test suite with the following command:
$ py.test --functional testing/