This commit is contained in:
William Fu-Hinthorn
2025-10-31 18:01:16 -07:00
parent 36bbdb290f
commit 720b59c107
2 changed files with 8 additions and 1 deletions
+8 -1
View File
@@ -18,6 +18,7 @@ logging.basicConfig(level=logging.INFO)
def test(config: pathlib.Path, port: int, tag: str, verbose: bool):
"""Spin up API with Postgres/Redis via docker compose and wait until ready."""
logger.info("Starting test...")
with Runner() as runner, Progress(message="Pulling...") as set:
# Detect docker/compose capabilities
capabilities = langgraph_cli.docker.check_capabilities(runner)
@@ -155,6 +156,7 @@ def test(config: pathlib.Path, port: int, tag: str, verbose: bool):
except Exception:
logger.exception("Failed to bring down compose stack")
pass
logger.info("Test finished")
@@ -166,5 +168,10 @@ if __name__ == "__main__":
parser.add_argument("-c", "--config", type=str, default="./langgraph.json")
parser.add_argument("-p", "--port", type=int, default=DEFAULT_PORT)
args = parser.parse_args()
test(pathlib.Path(args.config), args.port, args.tag, verbose=True)
try:
test(pathlib.Path(args.config), args.port, args.tag, verbose=True)
except BaseException:
logger.exception("Test failed")
raise
logger.info("Test execution finished")