PaymentModulesManagerImpl implements PaymentModulesManager { @Override public Collection<PaymentModule> getPaymentModules() { return Collections.unmodifiableCollection(paymentModulesMap.values()); } PaymentModulesManagerImpl(final ServiceLocator serviceLocator,
                                     final SystemService systemService,
                                     final ShopService shopService); @Override Collection<PaymentModule> getPaymentModules(); @Override Collection<PaymentGatewayDescriptor> getPaymentGatewaysDescriptors(final String paymentModuleLabel); @Override void allowPaymentGateway(final String label); @Override void allowPaymentGatewayForShop(final String label, final String shopCode); @Override void disallowPaymentGateway(final String label); @Override void disallowPaymentGatewayForShop(final String label, final String shopCode); @Override List<PaymentGatewayDescriptor> getPaymentGatewaysDescriptors(final boolean includeDisabled, final String shopCode); @Override PaymentGateway getPaymentGateway(final String paymentGatewayLabel, final String shopCode); @Override void register(final PaymentModule paymentModule);  }
@Test public void testGetPaymentModules() { Collection<PaymentModule> modules = paymentModulesManager.getPaymentModules(); assertEquals(1, modules.size()); Descriptor descriptor = modules.iterator().next().getPaymentModuleDescriptor(); assertEquals("basePaymentModule", descriptor.getLabel()); }