コード例 #1
0
        public async Task GetAllUsersAsyncTest_Empty()
        {
            var mockState         = new MockReliableStateManager();
            var userDomainService = new UserDomainService(mockState, this.statefulServiceContext);
            var result            = await userDomainService.GetAllUsersAsync();

            Assert.IsNotNull(result);
            Assert.IsTrue(result.Count == 0);
        }
コード例 #2
0
        public async Task GetAllUsersTestAsync_NotEmpty()
        {
            var mockState = await this.CreateMockStateManager();

            var userDomainService = new UserDomainService(mockState, this.statefulServiceContext);
            var result            = await userDomainService.GetAllUsersAsync();

            Assert.IsNotNull(result);
            Assert.IsTrue(result.Count == 1);
            Assert.IsTrue(result[0].IdCardNo == "111");
        }
コード例 #3
0
 public async Task <IList <User> > GetAllUsersAsync()
 {
     return(await _userDomainService.GetAllUsersAsync());
 }