public void FirstNameChange_GeneratesEvents()
 {
     var cust = new Customer();
     var viewModel = new CustomerModelView( cust );
     TestHelpers.DoInpcTest( viewModel, vm =>
         {
             vm.FirstName = "Test";
         }, 1, "FirstName");
 }
 public void FirstNameChange_GeneratesBusinessCardChangeNotification()
 {
     var cust = new Customer();
     var viewModel = new CustomerModelView(cust);
     TestHelpers.DoInpcTest(viewModel, vm =>
     {
         vm.FirstName = "Test";
     }, 1, "BusinessCard");
 }
        public void AccessingGetter_InBetweenEvents_Works()
        {
            var cust = new Customer();
            var viewModel = new CustomerModelView(cust);

            ((INotifyPropertyChanged) viewModel).PropertyChanged += ( s, e ) =>
                {
                    Assert.IsNotEmpty( viewModel.FirstName );
                    Assert.IsNull( viewModel.Address );
                };

            viewModel.FirstName = "Test";
        }
 public CustomerModelView(Customer customer)
 {
     this.customer = customer;
 }