3 Commits

8 changed files with 31 additions and 6 deletions

4
.gitmodules vendored
View File

@@ -1,9 +1,9 @@
[submodule "bot/gui"]
path = src/gui
url = https://github.com/StudyLions/StudyLion-Plugin-GUI.git
url = git@github.com:Intery/CafeHelper-GUI.git
[submodule "skins"]
path = skins
url = https://github.com/Intery/pillow-skins.git
url = git@github.com:Intery/CafeHelper-Skins.git
[submodule "src/modules/voicefix"]
path = src/modules/voicefix
url = https://github.com/Intery/StudyLion-voicefix.git

View File

@@ -11,3 +11,6 @@ pillow
python-dateutil
bidict
frozendict
TwitchIO
websockets
TwitchAPI

2
skins

Submodule skins updated: d3d6a28bc9...686857321e

Submodule src/gui updated: c1bcb05c25...40bc140355

7
tests/__init__.py Normal file
View File

@@ -0,0 +1,7 @@
# !/bin/python3
import sys
import os
sys.path.insert(0, os.path.join(os.getcwd()))
sys.path.insert(0, os.path.join(os.getcwd(), "src"))

0
tests/gui/__init__.py Normal file
View File

View File

@@ -1,11 +1,11 @@
import asyncio
import datetime as dt
from src.cards import WeeklyGoalCard
from gui.cards import WeeklyGoalCard
async def get_card():
card = await WeeklyGoalCard.generate_sample()
with open('samples/weekly-sample.png', 'wb') as image_file:
with open('output/weekly-sample.png', 'wb') as image_file:
image_file.write(card.fp.read())
if __name__ == '__main__':

View File

@@ -0,0 +1,15 @@
import asyncio
import datetime as dt
from gui.cards import BreakTimerCard, FocusTimerCard
async def get_card():
card = await BreakTimerCard.generate_sample()
with open('output/break_timer_sample.png', 'wb') as image_file:
image_file.write(card.fp.read())
card = await FocusTimerCard.generate_sample()
with open('output/focus_timer_sample.png', 'wb') as image_file:
image_file.write(card.fp.read())
if __name__ == '__main__':
asyncio.run(get_card())