Example #1
0
        public void TestExceptionPrompt_PromptsWithConstantTitle()
        {
            UserPromptWindow userPrompt =
                GetWindow(() => _objectUnderTest.ExceptionPrompt(new Exception()));

            Assert.AreEqual(Resources.ExceptionPromptTitle, userPrompt.Title);
        }
Example #2
0
 private async Task <IEnumerable <string> > ListAllLocationsAsync()
 {
     try
     {
         IEnumerable <string> result = (await _dataSource.GetFlexLocationsAsync()).OrderBy(x => x);
         SelectedLocation = DefaultRegionName;
         return(result);
     }
     catch (DataSourceException ex)
     {
         UserPromptUtils.ExceptionPrompt(ex);
         _owner.Close();
         return(Enumerable.Empty <string>());
     }
 }