Beispiel #1
0
 public function testItemsRemove()
 {
     $coreClient = new RingsideRestClient($this->fbClient);
     $coreClient->items_setInfo(123, 'http://localhost/foo.jpg', 'http://localhost/foo.html');
     $info = $coreClient->items_getInfo(123);
     $this->assertNotEquals(false, $info);
     $coreClient->items_remove(123);
     $info = $coreClient->items_getInfo(123);
     $this->assertEquals(false, $info);
 }
Beispiel #2
0
 * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
 * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
 ******************************************************************************/
require_once('ringside/core/client/RingsideRestClient.php');
require_once('config.php');

$server_url = "http://api.facebook.com/restserver.php";
$web_url = 'http://www.facebook.com';
try {
require_once('ringside/api/clients/RingsideApiClients.php');
$fb = new RingsideApiClients($api_key, $secret, $web_url, $server_url);
$ringside = new RingsideRestClient($fb->api_client);

$loggedinuser = $fb->require_login();
$fb->api_client->friends_get();

	$ringside->items_setInfo('testitem', RingsideRestClient::$server_url, 'http://'.$_SERVER['HTTP_HOST']);
	$item = $ringside->items_getInfo('testitem');
	if ($item) {
?>Test Passed<?
$ringside->items_remove('testitem');
	} else {
?>Test FAILED<?
	}
} catch ( Exception $e ) {
?>Test EXCEPTION<br><pre><?php
echo $e->getMessage()."\n";
echo $e->getTraceAsString();
}
?></pre>