Пример #1
0
        public void ShouldBeAbleToAssignedUserForAccount()
        {
            SugarEntry account = _cw.GetEntry(SugarModules.Accounts, GetAccountId());
            string     userId  = account["assigned_user_id"];

            Assert.IsNotEmpty(userId);
            SugarEntry user = _cw.GetEntry(SugarModules.Users, userId);

            Assert.IsNotNull(user);
            Console.WriteLine(user);
        }
Пример #2
0
 public void DemonstarteUsingPattern()
 {
     //Calls logout when done being used via IDisposable.
     using (var cw = new CandyWrapper(URL, USER, PWD))
     {
         SugarEntry entry = cw.GetEntry(SugarModules.Accounts, GetAccountId());
         Assert.IsNotNull(entry);
         Assert.IsNotEmpty(entry);
         Console.WriteLine(entry["name"]);
     }
 }
Пример #3
0
 public void DemonstarteUsingPattern()
 {
     //Calls logout when done being used via IDisposable.
     using (var cw = new CandyWrapper(URL, USER, PWD))
     {
         SugarEntry entry = cw.GetEntry(SugarModules.Accounts, GetAccountId());
         Assert.IsNotNull(entry);
         Assert.IsNotEmpty(entry);
         Console.WriteLine(entry["name"]);
     }
 }