You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I noticed that sometimes the comments felt out of place. I tracked this down to comments preceding the move property. I couldn't figure out a fix though. I hope the test case helps.
test("test for comments being attached to right nodes", () => {
let sgfStr = "(;GM[1]FF[4]CA[UTF-8]AP[CGoban:3]ST[2] RU[Japanese]SZ[19]KM[0.00]PW[White]PB[Black];W[aa]C[Comment after move property];W[pd])";
let goban = new TestGoban({ original_sgf: sgfStr, removed: "", });
goban.engine.jumpToOfficialMoveNumber(0);
expect(goban.engine.cur_move.text).toMatch("");
goban.engine.showNext();
expect(goban.engine.cur_move.text).toMatch("Comment after move property");
// now let's have the comment before the move property
sgfStr = "(;GM[1]FF[4]CA[UTF-8]AP[CGoban:3]ST[2] RU[Japanese]SZ[19]KM[0.00]PW[White]PB[Black];C[Comment before move property]W[aa];W[pd]C[second comment])";
goban = new TestGoban({ original_sgf: sgfStr, removed: "", });
goban.engine.jumpToOfficialMoveNumber(0);
expect(goban.engine.cur_move.text).toMatch("");
goban.engine.showNext();
expect(goban.engine.cur_move.text).toMatch("Comment before move property");
goban.engine.showNext();
expect(goban.engine.cur_move.text).toMatch("Second comment");
});
The text was updated successfully, but these errors were encountered:
If you can provide a link to an example game that would be very helpful, that way we have something we can start debugging from and validate works when a fix is released.
I noticed that sometimes the comments felt out of place. I tracked this down to comments preceding the move property. I couldn't figure out a fix though. I hope the test case helps.
The text was updated successfully, but these errors were encountered: