- /**
- * Tests PapStatisticsManager counts when policies are added to a subgroup.
- *
- * @throws Exception if an error occurs
- */
- @Test
- public void testDeployedPdpGroupCountStatistics() throws Exception {
- Registry.unregister(PapConstants.REG_STATISTICS_MANAGER);
- PapStatisticsManager mgr = new PapStatisticsManager();
- Registry.register(PapConstants.REG_STATISTICS_MANAGER, mgr);
-
- when(pdpGroupService.getFilteredPdpGroups(any())).thenReturn(loadGroups("deployPoliciesWildCard.json"));
- prov.deployPolicies(loadRequest("multiple_requests.json"), DEFAULT_USER);
- assertEquals(3, mgr.getTotalPolicyDeployCount());
-
- Registry.unregister(PapConstants.REG_STATISTICS_MANAGER);
- Registry.register(PapConstants.REG_STATISTICS_MANAGER, statsmanager);
- }
-