Python port of uzabase/playtest2
Project description
playtest2
Table of Contents
Installation
Prerequisites
Setting up Gauge with playtest2
- Install
playtest2as a uv tool:
$ uv tool install playtest2
This provides the playtest2 setup command from an isolated environment outside your E2E test project.
- Create a virtual environment for your E2E test project:
$ cd /path/to/e2e/project
$ python -m venv .venv --upgrade-deps
$ source .venv/bin/activate
- Install
playtest2in the E2E virtual environment too:
(.venv) $ python -m pip install playtest2
The uv tool installation is used for generating Gauge configuration. The E2E virtual environment installation is used when Gauge runs the Python steps.
Usage
Gauge Configuration
- From the E2E test project root, run the uv tool-installed
playtest2 setupto createpython.propertiesinenv/default/.
$ playtest2 setup
# If you have own step implementation directories
$ playtest2 setup your_step_impl1 your_step_impl2
[!TIP] Generated env/default/python.properties example
STEP_IMPL_DIR = /**absolute**/path/of/uv/tool/environment/lib/python3.x/site-packages/playtest2,your_step_impl1,your_step_impl2
[!IMPORTANT] Run
playtest2 setupusing the uv tool-installed command, not the command inside your E2E project's.venv. This keepssite-packages/playtest2outside the E2E project directory and avoids Gauge Python loader issues with project-local.venvpaths.
- Create
playtest2.propertiesinenv/default/.
SUT_BASE_URL = http://127.0.0.1:8000
Run gauge command in your E2E test project:
(.venv) $ gauge run specs
Spec example
# サンプルアプリのテスト
## GETリクエストが送れる
* パス"/"に
* メソッド"GET"で
* リクエストを送る
* レスポンスのボディが
* JSONのパス"$.message"に対応する値が
* 文字列の"Hello World"である
Development
Prerequisites: Hatch (Installation)
Lint
hatch fmt && hatch run types:check
Test
hatch test --randomize --doctest-modules
License
playtest2 is distributed under the terms of the MIT license.
Project details
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file playtest2-0.0.7.tar.gz.
File metadata
- Download URL: playtest2-0.0.7.tar.gz
- Upload date:
- Size: 9.3 kB
- Tags: Source
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.12
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
b88feaf4ea25b031ae1fe3eb0b4f937156eb5369c6f58cd4676bd3c3eaff2893
|
|
| MD5 |
4fe4d19b3805274f28d54793c2d06ec4
|
|
| BLAKE2b-256 |
5d8a5131dfa6ca33eda75033d33800b36fcf5a49648fa093b5f7c00d4340c650
|
Provenance
The following attestation bundles were made for playtest2-0.0.7.tar.gz:
Publisher:
publish.yaml on ftnext/playtest2-python
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
playtest2-0.0.7.tar.gz -
Subject digest:
b88feaf4ea25b031ae1fe3eb0b4f937156eb5369c6f58cd4676bd3c3eaff2893 - Sigstore transparency entry: 1938550724
- Sigstore integration time:
-
Permalink:
ftnext/playtest2-python@db50fef6646fa0799abf97e81f576c69df022242 -
Branch / Tag:
refs/tags/v0.0.7 - Owner: https://github.com/ftnext
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
publish.yaml@db50fef6646fa0799abf97e81f576c69df022242 -
Trigger Event:
release
-
Statement type:
File details
Details for the file playtest2-0.0.7-py3-none-any.whl.
File metadata
- Download URL: playtest2-0.0.7-py3-none-any.whl
- Upload date:
- Size: 7.2 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.12
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
3d799dde79a19d4e5fdc9607e051d63b315a3ec8e47729e55321bf2b641edb68
|
|
| MD5 |
bc013f8390f65fb39e2318886664cbfa
|
|
| BLAKE2b-256 |
5fb6ca3cefe05e45facdf81d3c1a618f22810469f3d7043f5fae7ec464c43af3
|
Provenance
The following attestation bundles were made for playtest2-0.0.7-py3-none-any.whl:
Publisher:
publish.yaml on ftnext/playtest2-python
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
playtest2-0.0.7-py3-none-any.whl -
Subject digest:
3d799dde79a19d4e5fdc9607e051d63b315a3ec8e47729e55321bf2b641edb68 - Sigstore transparency entry: 1938550941
- Sigstore integration time:
-
Permalink:
ftnext/playtest2-python@db50fef6646fa0799abf97e81f576c69df022242 -
Branch / Tag:
refs/tags/v0.0.7 - Owner: https://github.com/ftnext
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
publish.yaml@db50fef6646fa0799abf97e81f576c69df022242 -
Trigger Event:
release
-
Statement type: