public function testUpdateUserProfile_SetLangCode_LangCodeSet()
 {
     self::$environ->clean();
     // setup parameters
     $userId = self::$environ->createUser('username', 'name', '*****@*****.**');
     $params = array('id' => '', 'interfaceLanguageCode' => 'th');
     $newUserId = UserCommands::updateUserProfile($params, $userId);
     // user profile updated
     $user = new UserProfileModel($newUserId);
     $this->assertEquals('th', $user->interfaceLanguageCode);
     $this->assertEquals($newUserId, $userId);
 }
Exemplo n.º 2
0
 /**
  * Create/Update a User Profile
  *
  * @param array $params (encoded UserProfileModel)
  * @return string Id of written object
  */
 public function user_updateProfile($params)
 {
     return UserCommands::updateUserProfile($params, $this->userId);
 }