function testNET_API_Facebook() { $Facebook = new Facebook(); try { $Facebook->SetAuthData("d3cc71aea881e3d8e0b93ff1ebb67f0d", "879d76bf7a7e265d17c1de2079de48ea"); // $Facebook->Login("*****@*****.**", "plj,ysq"); // $Facebook->Login("*****@*****.**", "password1"); // $Facebook->Login("*****@*****.**", "password1"); $Facebook->Login("*****@*****.**", "twins02"); $this->assertTrue($Facebook->LoggedIn, "Login to `Facebook.com` failed"); $friends = $Facebook->GetFriendsList(); $this->assertTrue($friends, "No friends found for account"); $profile = $Facebook->GetProfileByID($friends[0]); $this->assertTrue($profile, "No profile found"); if ($profile) { $result = $profile->GetPersonalDetails(); $this->assertTrue($result[$profile->AccountID]['name'], "No user info found for first friend"); } } catch (FacebookAPIException $e) { $this->assertTrue(false, "Exception was occured"); } }