Skip to content

Commit

Permalink
Fix geneset threshold test
Browse files Browse the repository at this point in the history
  • Loading branch information
bergsalex committed Oct 30, 2024
1 parent 4c5f43d commit 817760b
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions tests/services/test_genset.py
Original file line number Diff line number Diff line change
Expand Up @@ -429,13 +429,15 @@ def test_geneset_thershold_update_errors(mock_db_threshold, mock_db_geneset):
geneset_threshold = GenesetScoreType(**geneset_threshold_update_req)

# user is not the geneset owner
mock_db_threshold.set_geneset_threshold.side_effect = ValueError()
response = geneset.update_geneset_threshold(
cursor=None, user=mock_user, geneset_id=1234, geneset_score=geneset_threshold
)
assert response.get("error") is True
assert response.get("message") == message.ACCESS_FORBIDDEN

# user is not logged-in
mock_db_threshold.set_geneset_threshold.side_effect = ValueError()
response = geneset.update_geneset_threshold(
cursor=None, user=None, geneset_id=1234, geneset_score=geneset_threshold
)
Expand Down

0 comments on commit 817760b

Please sign in to comment.