Esempio n. 1
0
        public async Task show_an_error_dialog_to_the_user_when_he_tries_to_save_a_topic_with_invalid_documents() {
            var topic = ATopicContainingADocumentWithEmptyTitle();
            var viewModel = new TopicVM(topicService, productRepository, topic, notificationSender);

            await ExecuteSaveTopicCommand(viewModel);

            notificationSender.Received(1).SendNotification("Debe facilitar un título para todos los documentos de este version range.");
        }
Esempio n. 2
0
        public async Task show_an_error_dialog_to_the_user_when_he_tries_to_save_a_topic_with_invalid_version_range() {
            var topic = ATopicContainingADescendentVersionRange();
            var viewModel = new TopicVM(topicService, productRepository, topic, notificationSender);

            await ExecuteSaveTopicCommand(viewModel);

            notificationSender.Received(1).SendNotification("No pueden existir rangos de versiones descendientes. \n" +
                                                            "Compruebe que todos los rangos para este topic son ascendientes.");
        }
Esempio n. 3
0
 private static async Task ExecuteSaveTopicCommand(TopicVM viewModel) {
     await viewModel.SaveTopic.ExecuteAsync(new object());
 }