Developers Manual > Cocos2d-x > Advanced Features > Third Party SDK Integration > Plugin-X > Facebook Support for Cocos2d-x Beta > Test Cases of Facebook Integration for Cocos2d-x and Cocos2d-x-lua

(!) Plugin-X is obsoleted. Please check out SDKBOX for helps with your service SDK integration.

Test Cases of Facebook Integration for Cocos2d-x and Cocos2d-x-lua

A Full Featured Test Case

To make it eaiser for all developers to start developing games with the Facebook Integration, we have provided a complete test case. It have covered all APIs and demonstrated how to correctly use them.

If you are not familiar with Facebook Integration for Cocos2d-x or Cocos2d-x-lua, we suggest you to take a look at the [Facebook Integration for Cocos2d-x or Cocos2d-x-lua API Reference].

There are two test cases which demostrate how to use the Facebook Integration in the Cocos2d-x or Cocos2d-x-lua.

For Cocos2d-x, you can refer to plugin/samples/HelloPlugins in the package of Cocos2d-x.**NOTE**:For iOS,you should run plugin/plugin-x_ios.xcworkspace

For Cocos2d-x-lua, you can run plugin/samples/HelloPluginsLua in the package of Cocos2d-x.

Facebook SDK User Test

In this test case, you can test follow functionalities of the Facebook Integration:

  • Login or logout an user to Facebook.
  • Retrieve the user id.
  • Retrieve the access token.
  • Invoke Open Graph API.
  • Retrieve permissions of your app via Open Graph API.
  • Send an activation event to Facebook.
  • Send an app event log to Facebook.
  • Send an in app purchase log to Facebook.

The explaintion of APIs covered in the API page:

Facebook SDK Share Test

All test in this page do not require user to login, you can test the following functionalities:

  • Share different links, an open graph story, a photo to your timeline or to your friends.
  • Send a message to your friends with links, an open graph story or a photo.
  • Send different app requests to your friends.

test_facebook_user.jpg (70 kB) samuele3hu, 2014-11-11 15:04

test_facebook_share.jpg (71.8 kB) samuele3hu, 2014-11-11 15:04

Sign up for our newsletter to keep up with the latest developments, releases and updates for Cocos2d-x.