Make tests pass on Chrome again
It seems that a number of the tests had started failing when run in Chrome. They were fine under PhantomJS, but the MegolmExport tests only work under Chrome, and I need them to work... Mostly the problems were timing-related, where assumptions made about how quickly the `then` handler on a promise would be called were no longer valid. Possibly Chrome 55 has made some changes to the relative priorities of setTimeout and sendMessage calls. One of the TimelinePanel tests was failing because it was expecting the contents of a div to take up more room than they actually were. It's possible this is something very environment-specific; hopefully the new value will work on a wider range of machines. Also some logging tweaks.
This commit is contained in:
parent
878e5593ba
commit
cd1cf09dc9
6 changed files with 56 additions and 21 deletions
|
@ -99,7 +99,11 @@ describe('TimelinePanel', function() {
|
|||
// the document so that we can interact with it properly.
|
||||
parentDiv = document.createElement('div');
|
||||
parentDiv.style.width = '800px';
|
||||
parentDiv.style.height = '600px';
|
||||
|
||||
// This has to be slightly carefully chosen. We expect to have to do
|
||||
// exactly one pagination to fill it.
|
||||
parentDiv.style.height = '500px';
|
||||
|
||||
parentDiv.style.overflow = 'hidden';
|
||||
document.body.appendChild(parentDiv);
|
||||
});
|
||||
|
@ -235,7 +239,7 @@ describe('TimelinePanel', function() {
|
|||
expect(client.paginateEventTimeline.callCount).toEqual(0);
|
||||
done();
|
||||
}, 0);
|
||||
}, 0);
|
||||
}, 10);
|
||||
});
|
||||
|
||||
it("should let you scroll down to the bottom after you've scrolled up", function(done) {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue