public void TestFixtureSetUp() { Configuration.ConfigWithEmbeddedXml(null, "application_config", Assembly.GetExecutingAssembly(), "Cooper.Sync.Test.ConfigFiles") .RenderProperties() .Castle(resolver => Resolve(resolver.Container)); //初始化同步锁 DependencyResolver.Resolve<ILockHelper>().Init<Account>(); DependencyResolver.Resolve<ILockHelper>().Init<GoogleConnection>(); _logger = DependencyResolver.Resolve<ILoggerFactory>().Create(GetType()); _sessionManager = DependencyResolver.Resolve<ISessionManager>(); _accountHelper = DependencyResolver.Resolve<IAccountHelper>(); _accountService = DependencyResolver.Resolve<IAccountService>(); _accountConnectionService = DependencyResolver.Resolve<IAccountConnectionService>(); _taskService = DependencyResolver.Resolve<ITaskService>(); _externalServiceProvider = DependencyResolver.Resolve<IExternalServiceProvider>(); _googleTokenService = DependencyResolver.Resolve<IGoogleTokenService>(); _syncProcessor = DependencyResolver.Resolve<IGoogleSyncProcesser>(); GoogleSyncSettings.ClientIdentifier = "234919028272-gsmmng06nheoih4ajp60oq8s33at1os0.apps.googleusercontent.com"; GoogleSyncSettings.ClientSecret = "jXcjxFzCQGferMI37I0GSc05"; }
public void TestFixtureSetUp() { Configuration.ConfigWithEmbeddedXml(null, "application_config", Assembly.GetExecutingAssembly(), "Cooper.Sync.Test.ConfigFiles") .RenderProperties() .Castle(resolver => Resolve(resolver.Container)); //初始化同步锁 DependencyResolver.Resolve <ILockHelper>().Init <Account>(); DependencyResolver.Resolve <ILockHelper>().Init <GoogleConnection>(); _logger = DependencyResolver.Resolve <ILoggerFactory>().Create(GetType()); _sessionManager = DependencyResolver.Resolve <ISessionManager>(); _accountHelper = DependencyResolver.Resolve <IAccountHelper>(); _accountService = DependencyResolver.Resolve <IAccountService>(); _accountConnectionService = DependencyResolver.Resolve <IAccountConnectionService>(); _taskService = DependencyResolver.Resolve <ITaskService>(); _externalServiceProvider = DependencyResolver.Resolve <IExternalServiceProvider>(); _googleTokenService = DependencyResolver.Resolve <IGoogleTokenService>(); _syncProcessor = DependencyResolver.Resolve <IGoogleSyncProcesser>(); GoogleSyncSettings.ClientIdentifier = "234919028272-gsmmng06nheoih4ajp60oq8s33at1os0.apps.googleusercontent.com"; GoogleSyncSettings.ClientSecret = "jXcjxFzCQGferMI37I0GSc05"; }
public GoogleSyncProcesser( ILockHelper lockHelper, ILoggerFactory loggerFactory, ISessionManager sessionManager, IAccountHelper accountHelper, IAccountService accountService, IAccountConnectionService accountConnectionService, ITaskService taskService, IExternalServiceProvider externalServiceProvider, IGoogleTokenService googleTokenService, IGoogleTaskSyncService googleTaskSyncService, IGoogleCalendarEventSyncService googleCalendarEventSyncService, IGoogleContactSyncService googleContactSyncService) : base(lockHelper, loggerFactory, sessionManager, accountHelper, accountService, accountConnectionService, taskService, externalServiceProvider) { lockHelper.Init <GoogleConnection>(); _googleTokenService = googleTokenService; _googleTaskSyncService = googleTaskSyncService; _googleCalendarEventSyncService = googleCalendarEventSyncService; _googleContactSyncService = googleContactSyncService; }
public GoogleSyncProcesser( ILockHelper lockHelper, ILoggerFactory loggerFactory, ISessionManager sessionManager, IAccountHelper accountHelper, IAccountService accountService, IAccountConnectionService accountConnectionService, ITaskService taskService, IExternalServiceProvider externalServiceProvider, IGoogleTokenService googleTokenService, IGoogleTaskSyncService googleTaskSyncService, IGoogleCalendarEventSyncService googleCalendarEventSyncService, IGoogleContactSyncService googleContactSyncService) : base(lockHelper, loggerFactory, sessionManager, accountHelper, accountService, accountConnectionService, taskService, externalServiceProvider) { lockHelper.Init<GoogleConnection>(); _googleTokenService = googleTokenService; _googleTaskSyncService = googleTaskSyncService; _googleCalendarEventSyncService = googleCalendarEventSyncService; _googleContactSyncService = googleContactSyncService; }