示例#1
0
        public async Task AppRegistryApiServicePagesDataLoadAsyncSuccess()
        {
            // arrange
            var fakeHttpClient = A.Fake <HttpClient>();

            var appRegistryApiService = new AppRegistryApiService(fakeApiDataProcessorService, fakeHttpClient, appRegistryClientOptions);

            // act
            await appRegistryApiService.PagesDataLoadAsync().ConfigureAwait(false);

            // assert
            A.CallTo(() => fakeApiDataProcessorService.PostAsync(A <HttpClient> .Ignored, A <Uri> .Ignored)).MustHaveHappenedOnceExactly();
        }
 public async Task PagesDataLoadAsync()
 {
     await apiDataProcessorService.PostAsync(httpClient, appRegistryClientOptions.BaseAddress).ConfigureAwait(false);
 }