xref: /libCEED/examples/python/conftest.py (revision 7b3ff0698626cc2e5ce463afc10290072fd55c90)
1*7b3ff069SJeremy L Thompson# Copyright (c) 2017-2025, Lawrence Livermore National Security, LLC and other CEED contributors
2*7b3ff069SJeremy L Thompson# All Rights Reserved. See the top-level LICENSE and NOTICE files for details.
3*7b3ff069SJeremy L Thompson#
4*7b3ff069SJeremy L Thompson# SPDX-License-Identifier: BSD-2-Clause
5*7b3ff069SJeremy L Thompson#
6*7b3ff069SJeremy L Thompson# This file is part of CEED:  http://github.com/ceed
7*7b3ff069SJeremy L Thompson
8*7b3ff069SJeremy L Thompsonimport pytest
9*7b3ff069SJeremy L Thompson
10*7b3ff069SJeremy L Thompson# -------------------------------------------------------------------------------
11*7b3ff069SJeremy L Thompson# Add --ceed command line argument
12*7b3ff069SJeremy L Thompson# -------------------------------------------------------------------------------
13*7b3ff069SJeremy L Thompson
14*7b3ff069SJeremy L Thompson
15*7b3ff069SJeremy L Thompsondef pytest_addoption(parser):
16*7b3ff069SJeremy L Thompson    parser.addoption("--ceed", action="store", default='/cpu/self/ref/blocked')
17*7b3ff069SJeremy L Thompson
18*7b3ff069SJeremy L Thompson
19*7b3ff069SJeremy L Thompson@pytest.fixture(scope='session')
20*7b3ff069SJeremy L Thompsondef ceed_resource(request):
21*7b3ff069SJeremy L Thompson    ceed_resource = request.config.option.ceed
22*7b3ff069SJeremy L Thompson
23*7b3ff069SJeremy L Thompson    return ceed_resource
24*7b3ff069SJeremy L Thompson
25*7b3ff069SJeremy L Thompson# -------------------------------------------------------------------------------
26