From: Ian Jackson Date: Sat, 13 Mar 2021 20:51:39 +0000 (+0000) Subject: at-otter hidde: Use api_piece_move_synch in one place X-Git-Tag: otter-0.4.0~84 X-Git-Url: https://www.chiark.greenend.org.uk/ucgi/~ianmdlvl/git?a=commitdiff_plain;h=42321984a86ba0f5b5c85f716e7e464776292754;p=otter.git at-otter hidde: Use api_piece_move_synch in one place Signed-off-by: Ian Jackson --- diff --git a/apitest/at-otter.rs b/apitest/at-otter.rs index ec4f467e..17dfa16a 100644 --- a/apitest/at-otter.rs +++ b/apitest/at-otter.rs @@ -505,9 +505,8 @@ impl Ctx { bob.synch()?; for (&pawn, &xoffset) in izip!(&a_pawns, [10,20].iter()) { - alice.api_with_piece_op(&a_pieces[pawn].id, "m", json![ - (a_pieces[hand].pos + PosC([xoffset, 0]))?.0 - ])?; + let pos = (a_pieces[hand].pos + PosC([xoffset, 0]))?; + alice.api_piece_move_synch(&mut a_pieces, pawn, pos)?; } alice.synchu(&mut a_pieces)?;