Halve the screen brightness from midnight to 6 am
Co-Authored-By: Claude Opus 5.5 <[email protected]>
This commit is contained in:
1 parent
3ad6dc6963
commit
33d14bd1ab
4 files changed
+20
-2
No files matched your search
@@ -26,6 +26,13 @@ def test_refresh_retries_every_fifteen_minutes_after_a_failure():
|
||||
assert app.refresh_due(last, datetime(2026, 10, 6, 12, 15), last_ok=False) is True
|
||||
|
||||
|
||||
def test_brightness_is_halved_from_midnight_to_six():
|
||||
assert app.brightness(datetime(2026, 10, 6, 23, 59), 50) == 50
|
||||
assert app.brightness(datetime(2026, 10, 7, 0, 0), 50) == 25
|
||||
assert app.brightness(datetime(2026, 10, 7, 5, 59), 50) == 25
|
||||
assert app.brightness(datetime(2026, 10, 7, 6, 0), 50) == 50
|
||||
|
||||
|
||||
def test_local_now_is_naive_prague_time(monkeypatch):
|
||||
monkeypatch.setenv("TZ", "UTC") # a container without a proper TZ
|
||||
time_module.tzset()
|
||||
|
||||
Reference in new issue
Block a user