Examples of coordinatorAddCourse()


Examples of teammates.TeammatesServlet.coordinatorAddCourse()

    Datastore.initialize();
    TeammatesServlet ts = new TeammatesServlet();
    String response;
   
    //normal course
    response = ts.coordinatorAddCourse(COURSE_ID, COURSE_NAME, GOOGLE_ID);
    assertEquals(RESPONSE_ADDED, response);

    //duplicate id
    response = ts.coordinatorAddCourse(COURSE_ID, COURSE_NAME, GOOGLE_ID);
    assertEquals(RESPONSE_EXISTS, response);
View Full Code Here

Examples of teammates.TeammatesServlet.coordinatorAddCourse()

    //normal course
    response = ts.coordinatorAddCourse(COURSE_ID, COURSE_NAME, GOOGLE_ID);
    assertEquals(RESPONSE_ADDED, response);

    //duplicate id
    response = ts.coordinatorAddCourse(COURSE_ID, COURSE_NAME, GOOGLE_ID);
    assertEquals(RESPONSE_EXISTS, response);
   
    //different id
    response = ts.coordinatorAddCourse("id1010", COURSE_NAME, GOOGLE_ID);
    assertEquals(RESPONSE_ADDED, response);
View Full Code Here

Examples of teammates.TeammatesServlet.coordinatorAddCourse()

    //duplicate id
    response = ts.coordinatorAddCourse(COURSE_ID, COURSE_NAME, GOOGLE_ID);
    assertEquals(RESPONSE_EXISTS, response);
   
    //different id
    response = ts.coordinatorAddCourse("id1010", COURSE_NAME, GOOGLE_ID);
    assertEquals(RESPONSE_ADDED, response);
   
    //different name
    response = ts.coordinatorAddCourse(COURSE_ID, "different name", GOOGLE_ID);
    assertEquals(RESPONSE_EXISTS, response);
View Full Code Here

Examples of teammates.TeammatesServlet.coordinatorAddCourse()

    //different id
    response = ts.coordinatorAddCourse("id1010", COURSE_NAME, GOOGLE_ID);
    assertEquals(RESPONSE_ADDED, response);
   
    //different name
    response = ts.coordinatorAddCourse(COURSE_ID, "different name", GOOGLE_ID);
    assertEquals(RESPONSE_EXISTS, response);
   
    //different coordinator
    response = ts.coordinatorAddCourse(COURSE_ID, COURSE_NAME, "different coordinator");
    assertEquals(RESPONSE_EXISTS, response);
View Full Code Here

Examples of teammates.TeammatesServlet.coordinatorAddCourse()

    //different name
    response = ts.coordinatorAddCourse(COURSE_ID, "different name", GOOGLE_ID);
    assertEquals(RESPONSE_EXISTS, response);
   
    //different coordinator
    response = ts.coordinatorAddCourse(COURSE_ID, COURSE_NAME, "different coordinator");
    assertEquals(RESPONSE_EXISTS, response);
  }
 
  /**
   * course id
View Full Code Here

Examples of teammates.TeammatesServlet.coordinatorAddCourse()

    TeammatesServlet ts = new TeammatesServlet();
    String response;
    String COURSE_ID_LOWER = "cs1101";
    String COURSE_ID_UPPER = "CS1101";
   
    response = ts.coordinatorAddCourse(COURSE_ID_LOWER, COURSE_NAME, GOOGLE_ID);
    assertEquals(RESPONSE_ADDED, response);
   
    response = ts.coordinatorAddCourse(COURSE_ID_LOWER, "sensitive course", GOOGLE_ID);
    assertEquals(RESPONSE_EXISTS, response);
   
View Full Code Here

Examples of teammates.TeammatesServlet.coordinatorAddCourse()

    String COURSE_ID_UPPER = "CS1101";
   
    response = ts.coordinatorAddCourse(COURSE_ID_LOWER, COURSE_NAME, GOOGLE_ID);
    assertEquals(RESPONSE_ADDED, response);
   
    response = ts.coordinatorAddCourse(COURSE_ID_LOWER, "sensitive course", GOOGLE_ID);
    assertEquals(RESPONSE_EXISTS, response);
   
    //TODO: change to insensitive
    response = ts.coordinatorAddCourse(COURSE_ID_UPPER, COURSE_NAME, GOOGLE_ID);
//    assertEquals(RESPONSE_EXISTS, response);
View Full Code Here

Examples of teammates.TeammatesServlet.coordinatorAddCourse()

   
    response = ts.coordinatorAddCourse(COURSE_ID_LOWER, "sensitive course", GOOGLE_ID);
    assertEquals(RESPONSE_EXISTS, response);
   
    //TODO: change to insensitive
    response = ts.coordinatorAddCourse(COURSE_ID_UPPER, COURSE_NAME, GOOGLE_ID);
//    assertEquals(RESPONSE_EXISTS, response);
   
    //TODO: change to insensitive
    response = ts.coordinatorAddCourse(COURSE_ID_UPPER, "sensitive course", GOOGLE_ID);
//    assertEquals(RESPONSE_EXISTS, response);
View Full Code Here

Examples of teammates.TeammatesServlet.coordinatorAddCourse()

    //TODO: change to insensitive
    response = ts.coordinatorAddCourse(COURSE_ID_UPPER, COURSE_NAME, GOOGLE_ID);
//    assertEquals(RESPONSE_EXISTS, response);
   
    //TODO: change to insensitive
    response = ts.coordinatorAddCourse(COURSE_ID_UPPER, "sensitive course", GOOGLE_ID);
//    assertEquals(RESPONSE_EXISTS, response);
  }
 
 
  /*---------------------------------------------------EXCEPTION TESTING---------------------------------------------------*/
 
View Full Code Here

Examples of teammates.TeammatesServlet.coordinatorAddCourse()

   * @throws Exception
   */
  @Test
  public void testAddCourseWithEmptyIDFailed() throws Exception {
    TeammatesServlet ts = new TeammatesServlet();
    ts.coordinatorAddCourse("", COURSE_NAME, GOOGLE_ID);
  }
 
  /**
   * empty name
   * @rule compulsory field
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.