private static AppBuildMessagesListViewModel GetViewModelWithOneMessageForEachIssueType()
		{
			var messagesList = new AppBuildMessagesListViewModel();
			messagesList.AddMessage(AppBuilderTestExtensions.AsBuildTestWarning("Test warning"));
			messagesList.AddMessage(AppBuilderTestExtensions.AsBuildTestError("Test error"));
			return messagesList;
		}
        private static AppBuildMessagesListViewModel GetViewModelWithOneMessageForEachIssueType()
        {
            var messagesList = new AppBuildMessagesListViewModel();

            messagesList.AddMessage(AppBuilderTestExtensions.AsBuildTestWarning("Test warning"));
            messagesList.AddMessage(AppBuilderTestExtensions.AsBuildTestError("Test error"));
            return(messagesList);
        }
		private static AppBuildMessagesListViewModel CreateViewModelWithDummyMessages()
		{
			var listViewModel = new AppBuildMessagesListViewModel();
			listViewModel.AddMessage(
				AppBuilderTestExtensions.AsBuildTestWarning("A simple build warning"));
			listViewModel.AddMessage(
				AppBuilderTestExtensions.AsBuildTestError("A simple build error"));
			listViewModel.AddMessage(
				AppBuilderTestExtensions.AsBuildTestError("A second simple build error"));
			return listViewModel;
		}
예제 #4
0
        private static AppBuildMessagesListViewModel CreateViewModelWithDummyMessages()
        {
            var listViewModel = new AppBuildMessagesListViewModel();

            listViewModel.AddMessage(
                AppBuilderTestExtensions.AsBuildTestWarning("A simple build warning"));
            listViewModel.AddMessage(
                AppBuilderTestExtensions.AsBuildTestError("A simple build error"));
            listViewModel.AddMessage(
                AppBuilderTestExtensions.AsBuildTestError("A second simple build error"));
            return(listViewModel);
        }
		public void AddDifferentMessages()
		{
			var messagesList = new AppBuildMessagesListViewModel();
			messagesList.AddMessage(
				AppBuilderTestExtensions.AsBuildTestWarning("A test warning for this test"));
			messagesList.AddMessage(
				AppBuilderTestExtensions.AsBuildTestError("A test error for this test"));
			messagesList.AddMessage(
				AppBuilderTestExtensions.AsBuildTestError("Just another test error for this test"));
			Assert.AreEqual(1, messagesList.Warnings.Count);
			Assert.AreEqual("1 Warning", messagesList.TextOfWarningCount);
			Assert.AreEqual(2, messagesList.Errors.Count);
			Assert.AreEqual("2 Errors", messagesList.TextOfErrorCount);
		}
        public void AddDifferentMessages()
        {
            var messagesList = new AppBuildMessagesListViewModel();

            messagesList.AddMessage(
                AppBuilderTestExtensions.AsBuildTestWarning("A test warning for this test"));
            messagesList.AddMessage(
                AppBuilderTestExtensions.AsBuildTestError("A test error for this test"));
            messagesList.AddMessage(
                AppBuilderTestExtensions.AsBuildTestError("Just another test error for this test"));
            Assert.AreEqual(1, messagesList.Warnings.Count);
            Assert.AreEqual("1 Warning", messagesList.TextOfWarningCount);
            Assert.AreEqual(2, messagesList.Errors.Count);
            Assert.AreEqual("2 Errors", messagesList.TextOfErrorCount);
        }