[TestFixtureSetUp] [RequiresSTA] public void TestSetup() { _thread = new Thread(new ThreadStart(() => { _application = new MockApplication(); //System.Windows.Application. _application.Run(true); })); _thread.SetApartmentState(ApartmentState.STA); _thread.Start(); _thread.Join(100000); model = _application.Container.Resolve(typeof(NewCaseViewModel)) as NewCaseViewModel; } [Test] public void TestSearchFunctionality() { Assert.True(model != null); if (model != null) { model.MemberToSearch = "raghu"; if (model.SearchCommand.CanExecute("")) { model.SearchCommand.Execute(""); } Assert.True(model.SearchedMembers != null); } } } here is my code here the nunit framework is calling the test method and i cant make the _thread Execute the line <code>model.MemberToSearch = "raghu";</code> this is the code written in the Setter of the MemberToSearch Property <pre lang="cs"> _memberToSearch = value; OnPropertyChanged("MemberToSearch"); ((DelegateCommand)_searchCommand).RaiseCanExecuteChanged();
var
This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)