public UserView()
        {
            InitializeComponent();
            HtmlPage.Document.SetProperty("title", "Silverlight Validation");

            vm = new UserViewModel(UserModel.Create(), UserModelValidator.Create());
            this.DataContext = vm;
        }
 public void WhenConstructed_WithGenericParams_ThenInstantiatesViewModel()
 {
     var vm = new UserViewModel(UserModel.Create(), UserModelValidator.Create());
     Assert.IsNotNull(vm);
 }
Esempio n. 3
0
 public static UserViewModel CreateValidUserViewModel()
 {
     var vm = new UserViewModel(UserModel.Create("dummy", "Dummy1", "*****@*****.**", new DateTime(1977, 01, 01)), UserModelValidatorFake.Create());
     vm.MonitorEvents();
     return vm;
 }
Esempio n. 4
0
 public static UserViewModel CreateInvalidUserViewModel()
 {
     var vm = new UserViewModel(UserModel.Create(), UserModelValidatorFake.Create());
     vm.MonitorEvents();
     return vm;
 }