Esempio n. 1
0
        public void GetMessages()
        {
            var notification = new Notification();
            notification.Register("field1", "message1");
            notification.Register("field2", "message2");
            notification.Register("field1", "message3");

            var messages = notification.GetMessagesFor("field1");
            Assert.AreEqual(new[] { "message1", "message3" }, messages);
        }
Esempio n. 2
0
 public void EmptyGetMessages()
 {
     var notification = new Notification();
     Assert.AreEqual(0, notification.GetMessagesFor("field").Length);
 }