Exemplo n.º 1
0
        public void Get_ValidRequest_LastRefreshIsNow()
        {
            //Arrange
            var request   = new GetReleasesHttpRequestMessageBuilder().Build();
            var dataModel = new DataModelBuilder().WithDefaultDataSet().Build();

            _releaseRepositoryMock.Setup((stub) => stub.GetReleaseData(It.IsAny <string>(), It.IsAny <int>()))
            .Returns(dataModel);

            //Act
            dynamic result = _sut.Get(request);

            //Assert
            Assert.IsNotNull(result, "Unexpected result");
            AssertionHelper.AssertDateTimeIsNow(result.lastRefresh);
        }