Fix bug in parser when there are hidden chars at beginning of pgn
This commit is contained in:
@@ -2691,5 +2691,20 @@ $pgn = '[Event "URS-ch23"]
|
||||
|
||||
|
||||
}
|
||||
|
||||
/**
|
||||
* @test
|
||||
*/
|
||||
public function shouldImportAllGames(){
|
||||
$pgn = file_get_contents("pgn/philadelphiainternational2019.pgn");
|
||||
// when
|
||||
$parser = new PgnParser();
|
||||
$parser->setPgnContent($pgn);
|
||||
$content = $parser->getUnparsedGames();
|
||||
// when
|
||||
|
||||
// then
|
||||
$this->assertEquals(132, $parser->countGames());
|
||||
}
|
||||
}
|
||||
|
||||
|
3140
test/pgn/philadelphiainternational2019.pgn
Normal file
3140
test/pgn/philadelphiainternational2019.pgn
Normal file
File diff suppressed because it is too large
Load Diff
Reference in New Issue
Block a user