Skip to content

Instantly share code, notes, and snippets.

@smcabrera
Created December 16, 2015 19:29
Show Gist options
  • Select an option

  • Save smcabrera/6b0f39992c0acc8f3f48 to your computer and use it in GitHub Desktop.

Select an option

Save smcabrera/6b0f39992c0acc8f3f48 to your computer and use it in GitHub Desktop.
describe('WhiteLabel.Views.ProposalRequests.EventSpace.AdditionalInfo', function() {
beforeEach(function() {
var html = '<section id="additional-info"></section>';
$('body').append($(html));
this.region = new Backbone.Marionette.Region({ el: '#additional-info' });
});
afterEach(function() {
this.region.$el.remove();
});
it('updates the proposal request when the Event Requirements Change', function() {
var proposalRequest = new WhiteLabel.Models.ProposalRequest();
var view = new WhiteLabel.Views.ProposalRequests.EventSpace.AdditionalInfo({ model: proposalRequest });
this.region.show(view);
view.$el.find('#function_description').val('Special Requests');
view.$el.find('#function_description').trigger('input');
expect(proposalRequest.get('function_description')).toEqual('Special Requests');
});
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment