コード例 #1
0
        public void SetUp()
        {
            _configContext = new ConfigContext
            {
                McpDb              = "Data Source=10.37.36.195;Initial Catalog=MCPDev;uid=gary;pwd=Unsoul418!;",
                UploadPath         = "C:/AppOs",
                ImageEndPoint      = "http://localhost:53322/app",
                IosDownloadAddress = "itms-services://?action=download-manifest&url="
            };

            //Fake service
            _httpContextAccessor = Substitute.For <IHttpContextAccessor>();
            _hrProxy             = Substitute.For <IHrProxy>();

            _targetObj = new AuthService(_configContext, _httpContextAccessor, _hrProxy);
        }
コード例 #2
0
        public void SetUp()
        {
            ExternalServicesConfig externalServicesConfig = new ExternalServicesConfig
            {
                Hr = new HR
                {
                    BaseUrl = "http://10.37.35.103:5100",
                    IdentityCertificationPath = "hrapi_external/Portal_dlemp",
                    Account  = "PortalAPP",
                    PassWord = "******"
                }
            };

            _optionsExternalServicesConfig = Options.Create(externalServicesConfig);

            _restfulApiClient = Substitute.For <IRestfulApiClient>();

            _targetObj = new HrProxy(_optionsExternalServicesConfig, _restfulApiClient);
        }
コード例 #3
0
ファイル: AuthService.cs プロジェクト: Gary418Wu/AppStore-MVC
 public AuthService(ConfigContext config, IHttpContextAccessor httpContextAccessor, IHrProxy hrProxy)
 {
     _connectionProvider  = new SqlConnectionProvider(config.McpDb);
     _httpContextAccessor = httpContextAccessor;
     _hrProxy             = hrProxy;
 }