mirror of
https://github.com/meta-llama/llama-stack.git
synced 2025-10-18 15:27:16 +00:00
a bunch of logger.info()s are good for server code to help debug in production, but we don't want them killing our unit test output :) --------- Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
20 lines
619 B
Python
20 lines
619 B
Python
# Copyright (c) Meta Platforms, Inc. and affiliates.
|
|
# All rights reserved.
|
|
#
|
|
# This source code is licensed under the terms described in the LICENSE file in
|
|
# the root directory of this source tree.
|
|
|
|
import os
|
|
import warnings
|
|
|
|
|
|
def pytest_sessionstart(session) -> None:
|
|
if "LLAMA_STACK_LOGGING" not in os.environ:
|
|
os.environ["LLAMA_STACK_LOGGING"] = "all=WARNING"
|
|
|
|
# Silence common deprecation spam during unit tests.
|
|
warnings.filterwarnings("ignore", category=DeprecationWarning)
|
|
warnings.filterwarnings("ignore", category=PendingDeprecationWarning)
|
|
|
|
|
|
pytest_plugins = ["tests.unit.fixtures"]
|