utils+helper+tests: Fix an issue with RandomPolicy

This commit also extends ndn::ScenarioHelper to expose the underlying
StackHelper for customization, as well as adds a basic test case for the
RandomPolicy.

Change-Id: Ieb948996497fd282f1afe4e7c102ec224299ac7f
diff --git a/helper/ndn-scenario-helper.cpp b/helper/ndn-scenario-helper.cpp
index 0c661da..1be86e6 100644
--- a/helper/ndn-scenario-helper.cpp
+++ b/helper/ndn-scenario-helper.cpp
@@ -144,5 +144,11 @@
   throw std::invalid_argument("Link between " + node1 + " and " + node2 + " does not exist");
 }
 
+StackHelper&
+ScenarioHelper::getStackHelper()
+{
+  return ndnHelper;
+}
+
 } // namespace ndn
 } // namespace ns3
diff --git a/helper/ndn-scenario-helper.hpp b/helper/ndn-scenario-helper.hpp
index 5131daa..52d19b7 100644
--- a/helper/ndn-scenario-helper.hpp
+++ b/helper/ndn-scenario-helper.hpp
@@ -181,6 +181,12 @@
   void
   disableStatusServer();
 
+  /**
+   * \brief Get NDN stack helper, e.g., to adjust its parameters
+   */
+  StackHelper&
+  getStackHelper();
+
 private:
   Ptr<Node>
   getOrCreateNode(const std::string& nodeName);