@Override public void run() { configUpdates.execute(configServiceWatchServiceExecutor); } }));
@Override public String getDescription() { return configUpdates.getDescription(); }
@Override public boolean updateConfiguration(ConfigGroup configGroup) { final Path filePath = resolveConfigGroupPath(configGroup); final String commitMessage = "Updated config " + filePath.getFileName(); return saveConfiguration(configGroup, filePath, commitMessage, false); }
@Before public void setup() throws IOException { fileSystemTestingUtils.setup(); when(systemRepository.getUri()).thenReturn("git://amend-repo-test"); marshaller = new ConfigGroupMarshaller(); configurationFactory = new ConfigurationFactoryImpl(new DefaultPasswordServiceImpl()); ioService = mockIoService(); configurationService = new ConfigurationServiceImpl(systemRepository, marshaller, identity, ioService, repoChangedEvent, spaceChangedEvent, changedEvent, fileSystemTestingUtils.getFileSystem()); }
@Inject public ConfigurationServiceImpl(final @Named("system") org.guvnor.structure.repositories.Repository systemRepository, final ConfigGroupMarshaller marshaller, final User identity, final @Named("configIO") IOService ioService, final @Repository Event<SystemRepositoryChangedEvent> repoChangedEvent, final @OrgUnit Event<SystemRepositoryChangedEvent> orgUnitChangedEvent, final Event<SystemRepositoryChangedEvent> changedEvent, final @Named("systemFS") FileSystem fs) { this.systemRepository = systemRepository; this.marshaller = marshaller; this.identity = identity; this.ioService = ioService; this.repoChangedEvent = repoChangedEvent; this.orgUnitChangedEvent = orgUnitChangedEvent; this.changedEvent = changedEvent; this.fs = fs; }
@Before public void setup() { passwordService = new DefaultPasswordServiceImpl(); configurationFactory = new ConfigurationFactoryImpl(passwordService); }
@Before public void setUp() throws Exception { workbenchConfigurationHelper = new WorkbenchConfigurationHelper(); workbenchConfigurationHelper.setConfigurationFactory( new ConfigurationFactoryImpl() ); }
public void flush(final @Observes @org.guvnor.structure.backend.config.Repository SystemRepositoryChangedEvent changedEvent) { reloadRepositories(); }
@Before public void setup() { passwordService = new DefaultPasswordServiceImpl(); configurationFactory = new MigrationConfigurationFactoryImpl(passwordService); }
private ConfigGroup createSpaceConfigGroup(final Space space, final List<Contributor> contributors) { final ConfigGroup configGroup = spy(new ConfigGroup()); configGroup.setName(space.getName()); configGroup.addConfigItem(configurationFactory.newConfigItem("space-contributors", contributors)); return configGroup; }
@Before public void setup() throws IOException { fileSystemTestingUtils.setup(); when(systemRepository.getUri()).thenReturn("git://amend-repo-test"); marshaller = new ConfigGroupMarshaller(); configurationFactory = new ConfigurationFactoryImpl(new DefaultPasswordServiceImpl()); ioService = mockIoService(); configurationService = new ConfigurationServiceImpl(systemRepository, marshaller, identity, ioService, repoChangedEvent, spaceChangedEvent, changedEvent, fileSystemTestingUtils.getFileSystem()); }
@Inject public MigrationConfigurationServiceImpl(final @Named("system") org.guvnor.structure.repositories.Repository systemRepository, final ConfigGroupMarshaller marshaller, final User identity, final @Named("configIO") IOService ioService, final @Repository Event<SystemRepositoryChangedEvent> repoChangedEvent, final @OrgUnit Event<SystemRepositoryChangedEvent> orgUnitChangedEvent, final Event<SystemRepositoryChangedEvent> changedEvent, final @Named("systemFS") FileSystem fs) { super(systemRepository, marshaller, identity, ioService, repoChangedEvent, orgUnitChangedEvent, changedEvent, fs); }
@Before public void setup() { passwordService = new DefaultPasswordServiceImpl(); configurationFactory = new ConfigurationFactoryImpl(passwordService); }
@Test public void backwardCompatibilityNullTest() { final ConfigurationFactory factory = new ConfigurationFactoryImpl(); final BackwardCompatibleUtil backwardUtil = new BackwardCompatibleUtil(factory); assertNull(backwardUtil.compat(null)); }
public void flush(final @Observes @org.guvnor.structure.backend.config.Repository SystemRepositoryChangedEvent changedEvent) { loadRepositories(); } }
@Override public void run() { configUpdates.execute(configServiceWatchServiceExecutor); } }));
@Override public String getDescription() { return configUpdates.getDescription(); }
@Override public boolean addConfiguration(final ConfigGroup configGroup) { final Path filePath = resolveConfigGroupPath(configGroup); final String commitMessage = "Created config " + filePath.getFileName(); return saveConfiguration(configGroup, filePath, commitMessage, true); }
@Inject public ConfigurationServiceImpl(final @Named("system") org.guvnor.structure.repositories.Repository systemRepository, final ConfigGroupMarshaller marshaller, final User identity, final @Named("configIO") IOService ioService, final @Repository Event<SystemRepositoryChangedEvent> repoChangedEvent, final @OrgUnit Event<SystemRepositoryChangedEvent> spaceChangedEvent, final Event<SystemRepositoryChangedEvent> changedEvent, final @Named("systemFS") FileSystem fs) { this.systemRepository = systemRepository; this.marshaller = marshaller; this.identity = identity; this.ioService = ioService; this.repoChangedEvent = repoChangedEvent; this.spaceChangedEvent = spaceChangedEvent; this.changedEvent = changedEvent; this.fs = fs; }
@Test public void backwardCompatibilityNullTest() { final ConfigurationFactory factory = new ConfigurationFactoryImpl(); final BackwardCompatibleUtil backwardUtil = new BackwardCompatibleUtil(factory); assertNull(backwardUtil.compat(null)); }