JJC's Card Game
This is a simple card played over a series of round. Each round, players draw one card. The player with the highest card received 2 points. Players with penalty cards lose a point. First player to 21 points wins.
Installation
Make sure you have python 3.6 or higher installed, then:
pip install jjc-card-game
Play
jjc-card-game
Then follow the on-screen rules and instructions.
Or try these more advanced options:
jjc-card-game -d Jonathan Nicholas Austinto play a game with these three players. The-dspeeds up gameplay by dealing all the cards at once.jjc-card-game --helpto see even more options
Development
Development tools: Windows 10, PowerShell, and PyCharm.
git clone https://github.com/jonathanchukinas/card_game.git
cd card_game
pip install flit # for build, packaging
python -m venv .venv # create virtual environment
.venv\scripts\activate # activate virtual environment
flit install --pth-file # set up editable install
# modify source code
jjc-card-game # run modified app
# repeat
deactivate # exit virtual environment
Running the tests
Test are written for pytest and automated by tox.
Game logic has 95% test coverage, while
the command-line interface / ouput has less than 50%.
To run all the tests:
pip install tox, pytest
cd path\to\project\directory
tox
Tests will be run against all these python versions, if you have them:
- v3.6
- v3.7
- v3.8
For a faster way to run tests:
pytest
Built With
python and python packages:
Authors
- Jonathan Chukinas - initial release
License
This project is licensed under the MIT License - see the LICENSE.md file for details
Acknowledgements
- Brian Okken for his Test & Code podcast and Python Testing with pytest book, which jump-started my testing knowledge early in 2019 and recently helped me integrate pytest, flit, and tox together.
- Luciano Ramalho for his outstanding Fluent Python, which taught me much of what I know about python under the hood, dunder methods, lru cache, and so much more.
Metadata
Release files for jjc-card-game 0.0.3
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | Actions |
|---|---|---|---|---|
| jjc-card-game-0.0.3.tar.gz | 11.8 kB | Without provenance | Details for jjc-card-game-0.0.3.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| jjc_card_game-0.0.3-py3-none-any.whl | Python 3 | none | any | Details for jjc_card_game-0.0.3-py3-none-any.whl |
Total release size: 32.7 kB
Release files / jjc-card-game-0.0.3.tar.gz
| Download URL | jjc-card-game-0.0.3.tar.gz |
|---|---|
| Size | 11.8 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
756abf8e265d8c1d9fe373f6ddb283150508939679be3b49433d8291a4a044c0
|
|
BLAKE2b-256 checksum How to use checksums |
f9d6f20bf2c6b25d44515ed0d88242000063d8b445fd50c4f6f3e749d74b93d9
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
python-requests/2.22.0
|
Release files / jjc_card_game-0.0.3-py3-none-any.whl
| Download URL | jjc_card_game-0.0.3-py3-none-any.whl |
|---|---|
| Size | 20.9 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
9dbfc7e664be365ac0e45964e5fc615d04c0cbf6bc98719aa34d25815dcb41e0
|
|
BLAKE2b-256 checksum How to use checksums |
311cfce501ff3477fa4b03716a3b562e099e68c4d3d5a3772a26409e215ce86d
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
python-requests/2.22.0
|
Security for jjc-card-game 0.0.3
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
No provenance found
None of the files in this release were uploaded with provenance metadata.
A note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.