|
|
@ -1,4 +1,5 @@ |
|
|
using System; |
|
|
using System; |
|
|
|
|
|
using System.Collections.Generic; |
|
|
using System.Linq; |
|
|
using System.Linq; |
|
|
using System.Threading.Tasks; |
|
|
using System.Threading.Tasks; |
|
|
using Microsoft.Extensions.DependencyInjection; |
|
|
using Microsoft.Extensions.DependencyInjection; |
|
|
@ -40,12 +41,29 @@ namespace Volo.Abp.Http.DynamicProxying |
|
|
[Fact] |
|
|
[Fact] |
|
|
public async Task GetList() |
|
|
public async Task GetList() |
|
|
{ |
|
|
{ |
|
|
var people = await _peopleAppService.GetListAsync(new PagedAndSortedResultRequestDto()) |
|
|
var people = await _peopleAppService.GetListAsync(new PagedAndSortedResultRequestDto()); |
|
|
; |
|
|
|
|
|
people.TotalCount.ShouldBeGreaterThan(0); |
|
|
people.TotalCount.ShouldBeGreaterThan(0); |
|
|
people.Items.Count.ShouldBe((int) people.TotalCount); |
|
|
people.Items.Count.ShouldBe((int) people.TotalCount); |
|
|
} |
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
[Fact] |
|
|
|
|
|
public async Task GetParams() |
|
|
|
|
|
{ |
|
|
|
|
|
var id1 = Guid.NewGuid(); |
|
|
|
|
|
var id2 = Guid.NewGuid(); |
|
|
|
|
|
|
|
|
|
|
|
var @params = await _peopleAppService.GetParams(new List<Guid> |
|
|
|
|
|
{ |
|
|
|
|
|
id1, |
|
|
|
|
|
id2 |
|
|
|
|
|
}, new[] {"name1", "name2"}); |
|
|
|
|
|
|
|
|
|
|
|
@params.ShouldContain(id1.ToString("N")); |
|
|
|
|
|
@params.ShouldContain(id2.ToString("N")); |
|
|
|
|
|
@params.ShouldContain("name1"); |
|
|
|
|
|
@params.ShouldContain("name2"); |
|
|
|
|
|
} |
|
|
|
|
|
|
|
|
[Fact] |
|
|
[Fact] |
|
|
public async Task Delete() |
|
|
public async Task Delete() |
|
|
{ |
|
|
{ |
|
|
@ -151,4 +169,4 @@ namespace Volo.Abp.Http.DynamicProxying |
|
|
result.Inner1.Inner2.Value3.ShouldBe("value three"); |
|
|
result.Inner1.Inner2.Value3.ShouldBe("value three"); |
|
|
} |
|
|
} |
|
|
} |
|
|
} |
|
|
} |
|
|
} |
|
|
|