Esempio n. 1
0
        public void ViewModelBaseNoChange()
        {
            var view = new PersonView("Unosquare");

            view.SetName("Unosquare");

            Assert.That(view.ChangeCounter, Is.EqualTo(0));
        }
Esempio n. 2
0
        public void ViewModelBaseInstance()
        {
            var fixture = new Fixture();
            var view    = new PersonView();
            var imax    = new Random().Next(10);

            for (var i = 0; i < imax; i++)
            {
                view.SetName(fixture.Create <string>());
            }

            Assert.That(view.ChangeCounter, Is.EqualTo(imax));
        }