Example #1
0
    /// <summary>
    /// test 5
    /// testing creating of new user with other user credentials
    /// </summary>
    /// <returns></returns>
    private string Test5()
    {
      Message m5 = new Message();
      m5.TestID = 5;
      m_clientapi = new ClientAPI();
      m_clientapi.SetRootServer(RootServerUrl);
      m_clientapi.SetAuthHostAddress(AuthServerUrl);
      m_clientapi.ConfigClient();
      if ((m_clientapi.CreateNewUser("hshen1", "ewewew", m_admintoken).valid))
      {
        m5.Passed = false;
        m5.Msg = "m_clientapi.CreateNewUser test2 fails";

      }
      else
      {
        m5.Passed = true;
        m5.Msg = "m_clientapi.CreateNewUser  test2 succeeds";
      }
      return m5.ToString();

    }
Example #2
0
 /// <summary>
 /// test 4 
 /// test to create a new user 
 /// </summary>
 /// <returns></returns>
 private string Test4()
 {
   Message m4 = new Message();
   m4.TestID = 4;
   m_clientapi = new ClientAPI();
   m_clientapi.SetRootServer(RootServerUrl);
   m_clientapi.SetAuthHostAddress(AuthServerUrl);
   m_clientapi.ConfigClient();
   if (m_clientapi.CreateNewUser("hshen", "hshen", "hshen").valid)
   {
     m4.Passed = false;
     m4.Msg = "m_clientapi.CreateNewUser test1 fails";
   }
   else
   {
     m4.Passed = true;
     m4.Msg = "m_clientapi.CreateNewUser test1 succeeds";
   }
   return m4.ToString();
 }