]> git.proxmox.com Git - mirror_xterm.js.git/blobdiff - src/SelectionModel.test.ts
Merge pull request #926 from ficristo/search-fix
[mirror_xterm.js.git] / src / SelectionModel.test.ts
index 6da3874bd40ed0e3ade296f0bdf3079bc1add443..b087944273a54da097fcbc9cc6f01c01245a2687 100644 (file)
@@ -5,6 +5,7 @@ import { assert } from 'chai';
 import { ITerminal } from './Interfaces';
 import { SelectionModel } from './SelectionModel';
 import {BufferSet} from './BufferSet';
+import { MockTerminal } from './utils/TestUtils';
 
 class TestSelectionModel extends SelectionModel {
   constructor(
@@ -22,7 +23,9 @@ describe('SelectionManager', () => {
   let model: TestSelectionModel;
 
   beforeEach(() => {
-    terminal = <any>{ cols: 80, rows: 2, ybase: 0 };
+    terminal = new MockTerminal();
+    terminal.cols = 80;
+    terminal.rows = 2;
     terminal.scrollback = 10;
     terminal.buffers = new BufferSet(terminal);
     terminal.buffer = terminal.buffers.active;