Handle linking to posts not on the first page on a thread view. Fixes bug #11318.

This commit is contained in:
Colin Kuskie 2010-01-05 20:52:27 -08:00
parent 7281a3dd8e
commit 173bec1574
3 changed files with 31 additions and 11 deletions

View file

@ -89,8 +89,8 @@ ok( !$posts->[0]->{'user.isVisitor'}, 'first post made by visitor');
ok( $posts->[0]->{'hideProfileUrl'}, 'hide profile url, and user is visitor');
ok( !$posts->[0]->{'lastReply.user.isVisitor'}, 'lastReply not made by visitor');
ok( $posts->[0]->{'lastReply.hideProfileUrl'}, 'lastReply hide profile url, since user is visitor');
is( $posts->[0]->{'lastReply.url'}, $threads[1]->getUrl.'#id'.$threads[1]->getId, 'lastReply url has a query fragment prefixed by "id"');
is( $posts->[0]->{'url'}, $threads[1]->getUrl.'#id'.$threads[1]->getId, 'url has a query fragment prefixed by "id"');
is( $posts->[0]->{'lastReply.url'}, $threads[1]->getUrl.'?pn=1#id'.$threads[1]->getId, 'lastReply url has a query fragment prefixed by "id"');
is( $posts->[0]->{'url'}, $threads[1]->getUrl.'?pn=1#id'.$threads[1]->getId, 'url has a query fragment prefixed by "id"');
###################################################################