Repository: activemq-artemis Updated Branches: refs/heads/master 72b85b193 -> 02fc3c50a
ARTEMIS-2220 Fix PageCursorStressTest::testSimpleCursorWithFilter NPE FakeQueue is not correctly setting the queue on its PageSubscription, leading to fail the test due to NPEs when PageSubscription::getQueue is being used. Project: http://git-wip-us.apache.org/repos/asf/activemq-artemis/repo Commit: http://git-wip-us.apache.org/repos/asf/activemq-artemis/commit/c1eba53b Tree: http://git-wip-us.apache.org/repos/asf/activemq-artemis/tree/c1eba53b Diff: http://git-wip-us.apache.org/repos/asf/activemq-artemis/diff/c1eba53b Branch: refs/heads/master Commit: c1eba53b77b22858af20fa536c295ff5d7604e93 Parents: 72b85b1 Author: Francesco Nigro <[email protected]> Authored: Fri Jan 4 23:50:56 2019 +0100 Committer: Clebert Suconic <[email protected]> Committed: Wed Jan 9 16:56:08 2019 -0500 ---------------------------------------------------------------------- .../artemis/tests/unit/core/postoffice/impl/FakeQueue.java | 3 +++ 1 file changed, 3 insertions(+) ---------------------------------------------------------------------- http://git-wip-us.apache.org/repos/asf/activemq-artemis/blob/c1eba53b/tests/unit-tests/src/test/java/org/apache/activemq/artemis/tests/unit/core/postoffice/impl/FakeQueue.java ---------------------------------------------------------------------- diff --git a/tests/unit-tests/src/test/java/org/apache/activemq/artemis/tests/unit/core/postoffice/impl/FakeQueue.java b/tests/unit-tests/src/test/java/org/apache/activemq/artemis/tests/unit/core/postoffice/impl/FakeQueue.java index 518fdb8..bea1167 100644 --- a/tests/unit-tests/src/test/java/org/apache/activemq/artemis/tests/unit/core/postoffice/impl/FakeQueue.java +++ b/tests/unit-tests/src/test/java/org/apache/activemq/artemis/tests/unit/core/postoffice/impl/FakeQueue.java @@ -735,6 +735,9 @@ public class FakeQueue extends CriticalComponentImpl implements Queue { public void setPageSubscription(PageSubscription sub) { this.subs = sub; + if (subs != null) { + sub.setQueue(this); + } } @Override
