| 41 ++index; |
41 ++index; |
| 42 GameState gamestate; |
42 GameState gamestate; |
| 43 gamestate_init(&gamestate); |
43 gamestate_init(&gamestate); |
| 44 CX_TEST_DO { |
44 CX_TEST_DO { |
| 45 int result = parse_pgn(pgn_data[index-1], &gamestate); |
45 int result = parse_pgn(pgn_data[index-1], &gamestate); |
| 46 char msg[32]; |
46 char msg[64]; |
| 47 sprintf(msg, "failed to parse game%03u.pgn", index); |
47 sprintf(msg, "failed to parse game%03u.pgn: code %d, pos: %zu", |
| |
48 index, result, pgn_error_position()); |
| 48 CX_TEST_ASSERTM(result == pgn_no_error, msg); |
49 CX_TEST_ASSERTM(result == pgn_no_error, msg); |
| 49 } |
50 } |
| 50 gamestate_cleanup(&gamestate); |
51 gamestate_cleanup(&gamestate); |
| 51 } |
52 } |
| 52 |
53 |