Add test fixtures
Test page loads fixtures and renders the inbox view. This may be useful for smoke testing style changes or generating screenshots with pseudo-realistic data. Includes a couple small changes to get rendering working outside the app.
This commit is contained in:
parent
89cd40c1f5
commit
b0c59233f3
5 changed files with 3150 additions and 90 deletions
17
test/fixtures_test.js
Normal file
17
test/fixtures_test.js
Normal file
|
@ -0,0 +1,17 @@
|
|||
'use strict';
|
||||
|
||||
describe("Fixtures", function() {
|
||||
before(function(done) {
|
||||
Whisper.Fixtures.saveAll().then(done);
|
||||
});
|
||||
it('renders', function(done) {
|
||||
ConversationController.updateInbox().then(function() {
|
||||
var view = new Whisper.InboxView({appWindow: {contentWindow: window}});
|
||||
view.$el.prependTo($('#render-android'));
|
||||
|
||||
var view = new Whisper.InboxView({appWindow: {contentWindow: window}});
|
||||
view.$el.removeClass('android').addClass('ios');
|
||||
view.$el.prependTo($('#render-ios'));
|
||||
}).then(done,done);
|
||||
});
|
||||
});
|
Loading…
Add table
Add a link
Reference in a new issue