diff --git a/test/metrics/test_rsquared.py b/test/metrics/test_rsquared.py
index ccf080a4310fadd1556b52f860b8800d3c521b62..cdc2518eb34dfa9753d7f2ba7f6e2d76c1785eb1 100644
--- a/test/metrics/test_rsquared.py
+++ b/test/metrics/test_rsquared.py
@@ -44,6 +44,7 @@ def test_case_fixture(
 ) -> MetricTestCase:
     """Return a test case for an R2 metric, with opt. sample weights."""
     # Generate random inputs and sample weights.
+    np.random.seed(20230301)
     y_true = np.random.normal(scale=1.0, size=32)
     y_pred = y_true + np.random.normal(scale=0.5, size=32)
     s_wght = np.abs(np.random.normal(size=32)) if weighted else np.ones((32,))