We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 5dcb7c9 commit 6c45f79Copy full SHA for 6c45f79
causalpy/tests/conftest.py
@@ -20,7 +20,7 @@
20
21
import numpy as np
22
import pytest
23
-from pymc.testing import mock_sample_setup_and_teardown
+from pymc.testing import mock_sample, mock_sample_setup_and_teardown
24
25
26
@pytest.fixture(scope="session")
@@ -31,3 +31,13 @@ def rng() -> np.random.Generator:
31
32
33
mock_pymc_sample = pytest.fixture(mock_sample_setup_and_teardown, scope="session")
34
+
35
36
+@pytest.fixture(autouse=True)
37
+def mock_sample_for_doctest(request):
38
+ if not request.config.getoption("--doctest-modules", default=False):
39
+ return
40
41
+ import pymc as pm
42
43
+ pm.sample = mock_sample
0 commit comments