diff --git a/test/backpack-controller.test.js b/test/backpack-controller.test.js index 6f51d6e1..15c930c2 100644 --- a/test/backpack-controller.test.js +++ b/test/backpack-controller.test.js @@ -92,6 +92,24 @@ test('backpack#settings works', function (t) { }); t.end(); }); + +test('backpack#facebookSharing', function (t) { + conmock({ + handler: backpack.facebookSharing, + request: { + body: { + accessToken: 'aaBBccDDeFgHiJkLMnOP', + badgeBodyHash: 'sillybadgehash', + userId: 'me', + comment: 'Commenting on my badge so others know how awesome I am!', + fbAutomaticPush: 'checked' + } + } + }, function (err, mock, req) { + if (err) throw err; + t.equal(mock.status, 303); + t.end(); + }); }); testUtils.finish(test); \ No newline at end of file