From 30818352b9e5ccc53a25c49580d50762ee352f0c Mon Sep 17 00:00:00 2001 From: jkobject Date: Wed, 4 Sep 2024 17:34:57 +0200 Subject: [PATCH] more tests --- tests/test_base.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/tests/test_base.py b/tests/test_base.py index 927cfbb..8365364 100644 --- a/tests/test_base.py +++ b/tests/test_base.py @@ -3,7 +3,7 @@ from scipy.sparse import csr_matrix import numpy as np -from grnndata import GRNAnnData +from grnndata import GRNAnnData, utils def test_base(): @@ -13,6 +13,7 @@ def test_base(): random_mask = np.random.choice([0, 1], size=random_matrix.shape, p=[0.8, 0.2]) sparse_random_matrix = csr_matrix(random_matrix * random_mask) grn = GRNAnnData(adata.copy(), grn=sparse_random_matrix) + utils.get_centrality(grn, top_k_to_disp=0) assert isinstance(grn, GRNAnnData), "grn should be an instance of GRNAnnData" assert grn.shape == adata.shape, "grn shape should match adata shape"