Ejemplo n.º 1
0
		public ContactView (Contact contact)
		{
			BaseViewModel.CreateAndBind<ContactViewModel> (this, contact);

			Title = "Contact";

			_contact = contact;

			Content = CreateView ();
		}
		public void should_get_profile_from_repo_on_initialize() {
			var profile = new Contact {
				First = "Jimi",
				Last = "Jamison",
				Role = "Lead Vocalist"
			};

			_repository.GetProfileResult = profile;
			_sut.Initialize ().Wait ();
			Assert.AreSame (profile, _sut.Profile);
		}
        public ContactCellViewModel (Contact contact)
        {
            Contact = contact;
			IsProxy = contact is ContactProxy;
            First = contact.First;
            Last = contact.Last;
            Company = contact.Company;
            Role = contact.Role;
            Email = contact.Email;
            Phone = contact.Phone;
            Twitter = contact.Twitter;
        }
		public void SaveProfile (Contact profile)
		{
			throw new NotImplementedException ();
		}
		public void SaveContact (Contact contact)
		{
			throw new NotImplementedException ();
		}
 public void should_get_profile_on_init() {
     var profile = new Contact ();
     _repository.GetProfileResult = profile;
     _sut.Initialize ().Wait ();
     Assert.AreSame (profile, _sut.Profile);
 }