jordanbray / chess

A rust library to manage chess move generation

Home Page:https://jordanbray.github.io/chess/

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Repetition in tests

mathprocessing opened this issue · comments

chess/src/game.rs

Lines 461 to 469 in ad13857

// three fold, but with a move at the end that breaks the draw cycle
let game =
fake_pgn_parser("1. Nc3 Nf6 2. Nb1 Ng8 3. Nc3 Nf6 4. Nb1 Ng8 5. Nc3 Nf6 6. Nb1 Ng8 7. e4");
assert!(!game.can_declare_draw());
// three fold, but with a move at the end that breaks the draw cycle
let game =
fake_pgn_parser("1. Nc3 Nf6 2. Nb1 Ng8 3. Nc3 Nf6 4. Nb1 Ng8 5. Nc3 Nf6 6. Nb1 Ng8 7. e4");
assert!(!game.can_declare_draw());