fix benchmark.

This commit is contained in:
Christopher Jeffrey
2013-08-11 05:30:04 -05:00
parent 15f6833598
commit 791127bc88
4 changed files with 64 additions and 23 deletions
+16 -3
View File
@@ -1,9 +1,15 @@
/**
* term.js
* Copyright (c) 2012-2013, Christopher Jeffrey (MIT License)
*/
var element = {
createElement: function() { return element; },
appendChild: function() {},
removeChild: function() {},
addEventListener: function() {},
removeEventListener: function() {},
setAttribute: function() {},
style: {}
};
@@ -12,13 +18,20 @@ window.navigator = { userAgent: '' };
window.document = element;
window.document.body = element;
var Terminal = require('../static/term');
element.ownerDocument = window.document;
window.document.defaultView = window;
var Terminal = require('../lib/term');
Terminal.cursorBlink = false;
var data = require('./data').data;
var term = new Terminal(250, 100);
term.open();
var term = new Terminal({
cols: 250,
rows: 100
});
term.open(element);
var time = new Date;
var t = 10;