GetResources() public method

Downloads the english language resources.
/// When no network connection is available ///
public GetResources ( Uri serverUri ) : string>.Dictionary
serverUri System.Uri
return string>.Dictionary
コード例 #1
0
        public void GetResourcesThrowsExceptionWithoutNetworkConnection()
        {
            TestHelpers.Disconnect();

            // Arrange
            var sut = new LanguageResourceProvider();
            Action getResources = () => sut.GetResources(TestConstants.ValidServerUri);

            // Act / Assert
            getResources.ShouldThrow<NotImplementedException>().Where(e => e.Message == "Network connection lost.");

            TestHelpers.Connect();
        }