test user

You can create a test user associated with a particular app using the Graph API with your app access token. You can specify whether this user has already installed your app as well as the set of permissions that your app is granted for this user by default upon creation. installed: This is a Boolean parameter to specify whether your app should be installed for the test user at the time of creation. It is true by default. name: This is an optional string parameter. You can specify a name for the test user you create. The specified name will also be used in the email address assigned to the test user. locale: This is an optional string parameter. You can specify a locale for the test user you create, the default is en_US. The list of supported locales is available as an XML file. permissions: This is a comma-separated list of extended permissions. Your app is granted these permissions for the new test user if installed is true. access_token: This is an app access token.

 get the app access token
$app_token_url = "https:graph.facebook.comoauthaccess_token?client_id=" . $appid ."&client_secret=" . $appsecret . "&grant_type=client_credentials";
$response = file_get_contents($app_token_url);
$params = null;
parse_str($response, $params);
 this is the app access token
$app_token=$params['access_token'];

 create test user
$create_user_url = "https:graph.facebook.com" . $appid . "accountstest-users?installed=true&name=John_Doe&locale=en_US&permissions=read_stream&method=post&access_token=" . $app_token;

 get all test users for an app
$get_users_url = "https:graph.facebook.com" . $appid . "accountstest-users?access_token=" . $app_token;

 make one test user become friends with another test user
$test_uid_1='';
$test_uid_1_token='';
$test_uid_2='';
$test_uid_2_token='';
 create friend request from test user 1 to test user 2
$frient_user_1_url = "https:graph.facebook.com" . $test_uid_1 . "friends" . $test_uid_2 . "?method=post&access_token=" . $test_uid_1_token;
 accept friend request between test user 1 and test user 2
$accept_friend_url="https:graph.facebook.com" . $test_uid_2 . "friends" . $test_uid_1 . "?method=post&access_token=" . $test_uid_2_token;

 change test user's name and password
$test_uid='';
$change_info_url = "https:graph.facebook.com" . $test_uid . "?password=NEW_PASSWORD&name=NEW_NAME&method=post&access_token=" . $app_token;

 delete a test user
$test_uid='';
$delete_test_user_url = "https:graph.facebook.com" . $test_uid . "?method=delete&access_token=" . $app_token;