mirror of
https://gitee.com/dotnetchina/OpenAuth.Net.git
synced 2025-04-05 17:38:01 +08:00
!15 update OpenAuth.App/Test/TestBase.cs.
Merge pull request !15 from sesamefly/N/A
This commit is contained in:
commit
35a13a4772
@ -1,4 +1,4 @@
|
||||
using System;
|
||||
using System;
|
||||
using System.IO;
|
||||
using System.Linq;
|
||||
using Autofac.Extensions.DependencyInjection;
|
||||
@ -27,7 +27,7 @@ namespace OpenAuth.App.Test
|
||||
serviceCollection.AddOptions();
|
||||
//读取OpenAuth.WebApi的配置文件用于单元测试
|
||||
var path = AppContext.BaseDirectory;
|
||||
int pos = path.IndexOf("OpenAuth.App");
|
||||
int pos = path.LastIndexOf("OpenAuth.");
|
||||
var basepath = Path.Combine(path.Substring(0,pos) ,"OpenAuth.WebApi");
|
||||
IConfiguration config = new ConfigurationBuilder()
|
||||
.SetBasePath(basepath)
|
||||
|
Loading…
Reference in New Issue
Block a user