[board] Implement a bunch of sight tests
This commit is contained in:
parent
2174bcf009
commit
3ba6722697
2 changed files with 111 additions and 0 deletions
|
@ -236,6 +236,12 @@ impl Position {
|
|||
.next()
|
||||
.unwrap();
|
||||
sight_of_opposing_player.is_set(king_square)
|
||||
}
|
||||
|
||||
#[cfg(test)]
|
||||
impl Position {
|
||||
pub(crate) fn test_set_en_passant_square(&mut self, square: Square) {
|
||||
self.en_passant_square = Some(square);
|
||||
}
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue