예제 #1
0
        public void test_101_getTutor_negative_input()
        {
            String s = "";

            try
            {
                IQueryable <User> test_collection = d.GetTutor(-1);
            }
            catch (Exception e)
            {
                s = e.ToString();
            }

            Assert.IsTrue(s.Contains("ArgumentOutOfRangeException"));
        }
예제 #2
0
 public AdminProjectGroupViewWrapper(int groupid)
 {
     projectGroup         = groupid;
     ProjectGroupMembers  = projectDAO.getProjectGroupMembers(groupid);
     CurrentProjectOwners = projectDAO.GetProjectOwners(groupid);
     CurrentTutor         = projectDAO.GetTutor(groupid);
     ProjectGroups        = projectDAO.getProjectGroupsByProject(ProjectGroupMembers.First().ProjectGroup.project_id);
     GroupMemberUserList  = new List <User>();
     foreach (ProjectMember member in ProjectGroupMembers)
     {
         GroupMemberUserList.Add(member.User);
     }
 }
예제 #3
0
 public void test_101_getTutor_negative_input()
 {
     String exception = "";
     Dictionary<string, string> b = new Dictionary<string, string>();
     try
     {
         IQueryable<User> test_collection = d.GetTutor(-1);
     }
     catch(Exception e)
     {
         s = e.ToString();
         exception = e.ToString();
     }
     Assert.AreEqual("", exception);
     Assert.IsTrue(b.Count > 0);
예제 #4
0
 private void FillTutors(ProjectGroup projectGroup)
 {
     Tutors = project.GetTutor(projectGroup.id);
 }
예제 #5
0
 public IQueryable <User> GetTutor(ProjectGroup group)
 {
     return(project.GetTutor(group.id));
 }