fix failing tests

This commit is contained in:
Jörg Breitbart
2019-12-06 17:00:46 +01:00
parent 0f83d645b6
commit 70dabf11db
2 changed files with 7 additions and 6 deletions
+4 -4
View File
@@ -7,7 +7,7 @@ import { assert, expect } from 'chai';
import { MockViewport, MockCompositionHelper, MockRenderer, TestTerminal } from './TestUtils.test';
import { DEFAULT_ATTR_DATA } from 'common/buffer/BufferLine';
import { CellData } from 'common/buffer/CellData';
import { IBufferService } from 'common/services/Services';
import { IBufferService, IUnicodeService } from 'common/services/Services';
import { Linkifier } from 'browser/Linkifier';
import { MockLogService, MockOptionsService, MockUnicodeService } from 'common/TestUtils.test';
import { IRegisteredLinkMatcher, IMouseZoneManager, IMouseZone } from 'browser/Types';
@@ -1047,7 +1047,7 @@ describe('Terminal', () => {
// to get the special handling of fullwidth, surrogate and combining chars in the input handler
beforeEach(() => {
terminal = new TestTerminal({ cols: 10, rows: 5 });
linkifier = new TestLinkifier((terminal as any)._bufferService);
linkifier = new TestLinkifier((terminal as any)._bufferService, (terminal as any)._unicodeService);
mouseZoneManager = new TestMouseZoneManager();
linkifier.attachToDom({} as any, mouseZoneManager);
});
@@ -1372,8 +1372,8 @@ describe('Terminal', () => {
});
class TestLinkifier extends Linkifier {
constructor(bufferService: IBufferService) {
super(bufferService, new MockLogService(), new MockOptionsService(), new MockUnicodeService());
constructor(bufferService: IBufferService, unicodeService: IUnicodeService) {
super(bufferService, new MockLogService(), new MockOptionsService(), unicodeService);
Linkifier._timeBeforeLatency = 0;
}
+3 -2
View File
@@ -9,12 +9,13 @@ import { IBufferLine } from 'common/Types';
import { Linkifier } from 'browser/Linkifier';
import { BufferLine } from 'common/buffer/BufferLine';
import { CellData } from 'common/buffer/CellData';
import { MockLogService, MockBufferService, MockOptionsService, MockUnicodeService } from 'common/TestUtils.test';
import { MockLogService, MockBufferService, MockOptionsService } from 'common/TestUtils.test';
import { IBufferService } from 'common/services/Services';
import { UnicodeService } from 'common/services/UnicodeService';
class TestLinkifier extends Linkifier {
constructor(bufferService: IBufferService) {
super(bufferService, new MockLogService(), new MockOptionsService(), new MockUnicodeService());
super(bufferService, new MockLogService(), new MockOptionsService(), new UnicodeService());
Linkifier._timeBeforeLatency = 0;
}