Skip to content

Commit 1884d34

Browse files
authored
Merge pull request #39 from Dendroculus/major-updates
Add CI workflow and test fixtures, update requirements
2 parents 3ca1927 + d132dd7 commit 1884d34

File tree

4 files changed

+62
-166
lines changed

4 files changed

+62
-166
lines changed

.github/workflows/python-tests.yml

Lines changed: 34 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,34 @@
1+
name: CI - Run tests
2+
3+
on:
4+
workflow_dispatch: {}
5+
push:
6+
branches: main
7+
pull_request:
8+
branches: main
9+
10+
jobs:
11+
test:
12+
runs-on: ubuntu-latest
13+
strategy:
14+
matrix:
15+
python-version: [3.10, 3.11, 3.12]
16+
17+
steps:
18+
- name: Checkout code
19+
uses: actions/checkout@v4
20+
21+
- name: Set up Python ${{ matrix.python-version }}
22+
uses: actions/setup-python@v4
23+
with:
24+
python-version: ${{ matrix.python-version }}
25+
cache: 'pip'
26+
27+
- name: Install dependencies
28+
run: |
29+
python -m pip install --upgrade pip
30+
pip install -r requirements-dev.txt
31+
32+
- name: Run tests
33+
run: |
34+
python -m pytest -q

requirements-dev.txt

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
-r requirements.txt
2+
pytest
3+
pytest-asyncio
4+
pytest-cov

requirements.txt

Lines changed: 5 additions & 164 deletions
Original file line numberDiff line numberDiff line change
@@ -1,164 +1,5 @@
1-
absl-py==2.3.1
2-
aiofiles==25.1.0
3-
aiohappyeyeballs==2.6.1
4-
aiohttp==3.12.14
5-
aiosignal==1.4.0
6-
aiosqlite==0.21.0
7-
altgraph==0.17.4
8-
annotated-types==0.7.0
9-
anyio==4.9.0
10-
asttokens==3.0.0
11-
astunparse==1.6.3
12-
async-timeout==5.0.1
13-
asyncgui==0.6.3
14-
asyncpg==0.31.0
15-
attrs==25.3.0
16-
audioop-lts==0.2.2
17-
bcrypt==5.0.0
18-
beautifulsoup4==4.13.5
19-
better-profanity==0.7.0
20-
blinker==1.9.0
21-
cachetools==6.2.3
22-
certifi==2025.8.3
23-
cffi==1.17.1
24-
charset-normalizer==3.4.3
25-
click==8.3.0
26-
colorama==0.4.6
27-
colorgram.py==1.2.0
28-
comm==0.2.3
29-
contourpy==1.3.3
30-
cycler==0.12.1
31-
debugpy==1.8.17
32-
decorator==5.2.1
33-
discord.py==2.6.4
34-
distro==1.9.0
35-
docopt==0.6.2
36-
docutils==0.22
37-
exceptiongroup==1.3.0
38-
executing==2.2.1
39-
fastapi==0.119.0
40-
filelock==3.13.1
41-
filetype==1.2.0
42-
Flask==3.1.2
43-
flatbuffers==25.9.23
44-
fonttools==4.60.1
45-
frozenlist==1.7.0
46-
fsspec==2024.6.1
47-
gast==0.6.0
48-
git-filter-repo==2.47.0
49-
google-pasta==0.2.0
50-
grpcio==1.76.0
51-
h11==0.14.0
52-
h5py==3.15.1
53-
httpcore==0.17.3
54-
httpx==0.24.1
55-
idna==3.10
56-
importlib_metadata==8.7.0
57-
iniconfig==2.3.0
58-
ipykernel==6.30.1
59-
ipython==9.5.0
60-
ipython_pygments_lexers==1.1.1
61-
ipywidgets==8.1.7
62-
itsdangerous==2.2.0
63-
jedi==0.19.2
64-
Jinja2==3.1.4
65-
jiter==0.10.0
66-
joblib==1.5.2
67-
jupyter_client==8.6.3
68-
jupyter_core==5.8.1
69-
jupyterlab_widgets==3.0.15
70-
keras==3.12.0
71-
kiwisolver==1.4.9
72-
libclang==18.1.1
73-
Markdown==3.9
74-
markdown-it-py==4.0.0
75-
MarkupSafe==2.1.5
76-
materialyoucolor==2.0.10
77-
matplotlib==3.10.6
78-
matplotlib-inline==0.1.7
79-
mdurl==0.1.2
80-
ml_dtypes==0.5.3
81-
mpmath==1.3.0
82-
multidict==6.6.3
83-
mypy_extensions==1.1.0
84-
namex==0.1.0
85-
nest-asyncio==1.6.0
86-
networkx==3.2.1
87-
numpy==2.3.2
88-
openai==1.97.1
89-
opt_einsum==3.4.0
90-
optree==0.17.0
91-
packaging==25.0
92-
pandas==2.3.2
93-
parso==0.8.5
94-
patsy==1.0.2
95-
pefile==2023.2.7
96-
pillow==11.3.0
97-
pipreqs==0.4.13
98-
platformdirs==4.4.0
99-
playsound==1.2.2
100-
pluggy==1.6.0
101-
prettytable==3.16.0
102-
prompt_toolkit==3.0.52
103-
propcache==0.3.2
104-
protobuf==6.33.0
105-
psutil==7.1.0
106-
pure_eval==0.2.3
107-
pycparser==2.22
108-
pydantic==2.11.7
109-
pydantic_core==2.33.2
110-
pygame==2.6.1
111-
Pygments==2.19.2
112-
pyinstaller==6.15.0
113-
pyinstaller-hooks-contrib==2025.8
114-
PyNaCl==1.5.0
115-
pyparsing==3.2.5
116-
pypiwin32==223
117-
pytest==9.0.2
118-
pytest-asyncio==1.3.0
119-
python-dateutil==2.9.0.post0
120-
python-dotenv==1.1.1
121-
pytz==2025.2
122-
pywin32==311
123-
pywin32-ctypes==0.2.3
124-
pyzmq==27.1.0
125-
redis==7.1.0
126-
requests==2.32.5
127-
rich==14.2.0
128-
ruff==0.14.9
129-
scikit-learn==1.7.2
130-
scipy==1.16.2
131-
seaborn==0.13.2
132-
setuptools==68.2.2
133-
six==1.17.0
134-
sniffio==1.3.0
135-
soupsieve==2.8
136-
stack-data==0.6.3
137-
starlette==0.48.0
138-
statsmodels==0.14.5
139-
sympy==1.14.0
140-
tensorboard==2.20.0
141-
tensorboard-data-server==0.7.2
142-
tensorflow==2.20.0
143-
termcolor==3.2.0
144-
threadpoolctl==3.6.0
145-
torch==2.9.0
146-
tornado==6.5.2
147-
tqdm==4.67.1
148-
traitlets==5.14.3
149-
typing-inspect==0.9.0
150-
typing-inspection==0.4.1
151-
typing_extensions==4.15.0
152-
tzdata==2025.2
153-
urllib3==2.5.0
154-
wcwidth==0.2.13
155-
webserver==0.10.3
156-
Werkzeug==3.1.3
157-
wheel==0.45.1
158-
widgetsnbextension==4.0.14
159-
wrapt==2.0.0
160-
yarg==0.1.10
161-
yarl==1.20.1
162-
youtube-search-python==1.6.6
163-
yt-dlp==2025.6.30
164-
zipp==3.23.0
1+
discord.py
2+
better-profanity
3+
aiohttp
4+
python-dotenv
5+
asyncpg

tests/conftest.py

Lines changed: 19 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,24 @@
1-
# tests/conftest.py
21
import sys
32
from pathlib import Path
3+
import types
4+
import pytest
45

56
REPO_ROOT = Path(__file__).resolve().parent.parent
67
if str(REPO_ROOT) not in sys.path:
7-
sys.path.insert(0, str(REPO_ROOT))
8+
sys.path.insert(0, str(REPO_ROOT))
9+
10+
class DummyChannel:
11+
def __init__(self): self.sent = []
12+
async def send(self, *args, **kwargs): self.sent.append((args, kwargs))
13+
class DummyCtx:
14+
def __init__(self):
15+
self.channel = DummyChannel()
16+
self.author = types.SimpleNamespace(id=1, mention="<@1>")
17+
18+
@pytest.fixture
19+
def dummy_ctx():
20+
return DummyCtx()
21+
22+
@pytest.fixture
23+
def dummy_channel():
24+
return DummyChannel()

0 commit comments

Comments
 (0)