Skip to content

Commit

Permalink
add uv run instructions for test running
Browse files Browse the repository at this point in the history
  • Loading branch information
Esgrove committed Sep 16, 2024
1 parent 11325b8 commit a8cfddd
Showing 1 changed file with 9 additions and 4 deletions.
13 changes: 9 additions & 4 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -14,31 +14,36 @@ Home Assistant integration for Extron switchers and audio processors.

## Requirements

Devices must have Telnet access enabled
Devices must have Telnet access enabled.

## Features

Obviously, not every single feature can be controlled, only the basics:
Not every single feature can be controlled, only the basics:

* Media player support
* Source selection
* Volume control (SSP 200 only)
* Reboot button
* Temperature sensor (SSP 200 only)

The communication is done using Python's `asyncio` and requires no external libraries
The communication is done using Python's `asyncio` and requires no external libraries.

## Development

For local development,
use [uv](https://github.com/astral-sh/uv) to handle the Python dependencies and virtual env.
Install uv with their standalone installer script or with package managers like homebrew.
Then use `uv sync` to automatically create a virtual env and install the dependencies.

Use `uv sync` to automatically create a virtual env and install the dependencies.

Update all dependencies with `uv lock --upgrade`.

### Tests

```bash
# Using uv managed virtual env
uv run python -m unittest discover -s tests/ -v
# Manually activated virtual env with necessary dependencies
python3 -m unittest discover -s tests/ -v
```

Expand Down

0 comments on commit a8cfddd

Please sign in to comment.