mirror of
https://github.com/elder-plinius/OBLITERATUS.git
synced 2026-08-31 07:00:37 +02:00
fix: make supervised pipeline timeout configurable (#185)
This commit is contained in:
@@ -13,10 +13,23 @@ def test_active_checkpoint_survives_cleanup_and_remains_chat_recoverable(tmp_pat
|
||||
"""Exercise app state in isolation from Gradio's import-time worker sockets."""
|
||||
script = r'''
|
||||
import pathlib
|
||||
import os
|
||||
import sys
|
||||
|
||||
import app
|
||||
|
||||
assert app._pipeline_timeout_seconds() == 2700
|
||||
os.environ["OBLITERATUS_PIPELINE_TIMEOUT_SECONDS"] = "7200"
|
||||
assert app._pipeline_timeout_seconds() == 7200
|
||||
os.environ["OBLITERATUS_PIPELINE_TIMEOUT_SECONDS"] = "invalid"
|
||||
try:
|
||||
app._pipeline_timeout_seconds()
|
||||
except ValueError as error:
|
||||
assert "must be an integer" in str(error)
|
||||
else:
|
||||
raise AssertionError("invalid pipeline timeout was accepted")
|
||||
os.environ.pop("OBLITERATUS_PIPELINE_TIMEOUT_SECONDS")
|
||||
|
||||
theme = app.THEME.to_dict()["theme"]
|
||||
assert theme["body_background_fill"] != theme["body_background_fill_dark"]
|
||||
assert theme["body_text_color"] != theme["body_text_color_dark"]
|
||||
|
||||
Reference in New Issue
Block a user