A framework for implementing boardgames.
The idea is that the components here can be used with game specific modules that import and use or simply "configure-together" game components with config files.
A BoardGame project framework by Kyle Stapp.
Checkout the code:
git clone http://github.com/RabidCicada/boardgame_framework
Install Dependencies:
cd dev
pip install requirements.txt
Install Dev Dependencies then:
cd docs
make
To have pbr generate Changelog and AUTHORS automatically:
python setup.py sdist
Quick and Dirty:
cd src/
python -m pytest ../tests
or
python -m pytest ../tests --log-cli-level DEBUG -s
The Right Way:
tox
We use tox. It builds virtual environments defined in tox.ini for different versions of python, then builds the installable package, then installs it, then runs the tests. It does this for all the versions you have defined and is suitable for continuous integration.
It is intentional that you cannot run a normal pytest command without PYTHONPATH tomfoolery or calling pytest in the manner we show above for Quick and Dirty. By not being importable it prevents a whole class of testing problems related to accidentally getting your local dev code instead of what is installed by the package.
- Why this directory structure?
- https://blog.ionelmc.ro/2014/05/25/python-packaging/#the-structure
- Why only python3?
- I didn't want to deal with compatibility.
- Why Sphinx/restructured text instead of markdown?
- Ultimately because restructured text is more flexible and it is automatically usable by readthedocs. Also, http://www.zverovich.net/2016/06/16/rst-vs-markdown.html.
- Why Apache2 license?
- I want people to be able to do pretty much whatever they want. But want to protect the project itself.