Skip to content

Commit

Permalink
fix cloud test to use mock response
Browse files Browse the repository at this point in the history
  • Loading branch information
guidopetri committed Aug 26, 2024
1 parent df80a98 commit b8f0cf5
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions tests/test_transforms.py
Original file line number Diff line number Diff line change
Expand Up @@ -219,9 +219,11 @@ def test_fix_provisional_columns_full_data():
pd.testing.assert_frame_equal(parsed, clean, check_like=True)


def test_get_sf_evaluation_cloud():
def test_get_sf_evaluation_cloud(mocker):
mock_parsed_resp = {'pvs': [{'cp': -30}]}

mocker.patch('lichess.api.cloud_eval', return_value=mock_parsed_resp)

# this specific FEN is already evaluated by lichess
fen = 'r1bqkb1r/pp1ppppp/2n2n2/2p5/8/1P3NP1/PBPPPP1P/RN1QKB1R b KQkq - 0 1'

# loc/depth don't matter
Expand Down

0 comments on commit b8f0cf5

Please sign in to comment.