Skip to content

Commit 0c2944b

Browse files
committed
See if we can remove conditional check for UnixTerminal
1 parent 5850ab9 commit 0c2944b

File tree

1 file changed

+2
-6
lines changed

1 file changed

+2
-6
lines changed

src/unixTerminal.test.ts

Lines changed: 2 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,7 @@
33
* Copyright (c) 2018, Microsoft Corporation (MIT License).
44
*/
55

6+
import { UnixTerminal } from './unixTerminal';
67
import * as assert from 'assert';
78
import * as cp from 'child_process';
89
import * as path from 'path';
@@ -11,15 +12,10 @@ import * as fs from 'fs';
1112
import { constants } from 'os';
1213
import { pollUntil } from './testUtils.test';
1314
import { pid } from 'process';
14-
import type { UnixTerminal as UnixTerminalType } from './unixTerminal';
1515

1616
const FIXTURES_PATH = path.normalize(path.join(__dirname, '..', 'fixtures', 'utf8-character.txt'));
1717

1818
if (process.platform !== 'win32') {
19-
// Only load UnixTerminal on non-Windows platforms
20-
// This prevents trying to access winpty.node that doesn't exist anymore.
21-
// eslint-disable-next-line @typescript-eslint/naming-convention
22-
const { UnixTerminal } = require('./unixTerminal') as { UnixTerminal: typeof UnixTerminalType };
2319
describe('UnixTerminal', () => {
2420
describe('Constructor', () => {
2521
it('should set a valid pts name', () => {
@@ -79,7 +75,7 @@ if (process.platform !== 'win32') {
7975
});
8076

8177
describe('open', () => {
82-
let term: UnixTerminalType;
78+
let term: UnixTerminal;
8379

8480
afterEach(() => {
8581
if (term) {

0 commit comments

Comments
 (0)