Sha256: 37f41701b4f424f63560cc1d69198eb9a8b669227c38e8fb16675f36c713cee2
Contents?: true
Size: 1.96 KB
Versions: 16
Compression:
Stored size: 1.96 KB
Contents
{I" class:ETI"BundledAsset; FI"logical_path; TI"&social_networking/notices_spec.js; FI" pathname; TI"p/Users/usabilitymonitor/Desktop/Github/social_networking/spec/javascripts/social_networking/notices_spec.js; FI"content_type; TI"application/javascript; TI" mtime; Tl+¢¿UI"length; TĩI"digest; TI"%a4180f3ccf1148b67f4133994579f654; FI"source; TI"̃describe('Notice', function() { var server, noticeUtility, callback; var actionType, description, participantId; beforeEach(function() { actionType = "SocialNetworking::Goal"; description = "Completed a goal." participantId = 1; server = sinon.fakeServer.create(); callback = sinon.spy(); noticeUtility = window.Notice }); afterEach(function() { server.restore(); }); describe('#behaviorPostNotice', function() { it('should trigger #behaviorRealTimeToast upon success', function() { expect(noticeUtility.behaviorPostNotice).toBeTruthy(); noticeUtility.behaviorRealTimeToast = callback; noticeUtility.behaviorPostNotice(actionType, description, participantId); expect(server.requests.length).toBe(1); expect(server.requests[0].url).toBe("/participant_behaviors/complete"); }); }); describe('#incentivePostNotice', function() { it('should trigger #incentivRealTimeToast upon success', function() { expect(noticeUtility.incentivePostNotice).toBeTruthy(); noticeUtility.incentivRealTimeToast = callback; noticeUtility.incentivePostNotice(actionType, description, participantId); expect(server.requests.length).toBe(1); expect(server.requests[0].url).toBe("/participant_incentives/complete"); }); }); it('should offer a public incentive specific notification function (behaviorPostNotice)', function() { expect(noticeUtility.behaviorPostNotice).toBeTruthy(); }); }); ; TI"required_assets_digest; TI"%1a2f2043e2b04108e9447f66b19c84f0; FI" _version; TI"%069e88c06b889877799890854d7f4c40; F
Version data entries
16 entries across 8 versions & 1 rubygems