Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Remove check proposed api checks #4204

Merged
merged 2 commits into from Oct 15, 2022
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
3 changes: 0 additions & 3 deletions src/browser/public/Terminal.ts
Expand Up @@ -78,7 +78,6 @@ export class Terminal implements ITerminalApi {

public get element(): HTMLElement | undefined { return this._core.element; }
public get parser(): IParser {
this._checkProposedApi();
if (!this._parser) {
this._parser = new ParserApi(this._core);
}
Expand All @@ -92,7 +91,6 @@ export class Terminal implements ITerminalApi {
public get rows(): number { return this._core.rows; }
public get cols(): number { return this._core.cols; }
public get buffer(): IBufferNamespaceApi {
this._checkProposedApi();
if (!this._buffer) {
this._buffer = new BufferNamespaceApi(this._core);
}
Expand Down Expand Up @@ -148,7 +146,6 @@ export class Terminal implements ITerminalApi {
this._core.attachCustomKeyEventHandler(customKeyEventHandler);
}
public registerLinkProvider(linkProvider: ILinkProvider): IDisposable {
this._checkProposedApi();
return this._core.registerLinkProvider(linkProvider);
}
public registerCharacterJoiner(handler: (text: string) => [number, number][]): number {
Expand Down
2 changes: 1 addition & 1 deletion src/headless/public/Terminal.test.ts
Expand Up @@ -22,7 +22,7 @@ describe('Headless API Tests', function (): void {

it('Proposed API check', async () => {
term = new Terminal({ allowProposedApi: false });
throws(() => term.buffer, (error) => error.message === 'You must set the allowProposedApi option to true to use proposed API');
throws(() => term.markers, (error) => error.message === 'You must set the allowProposedApi option to true to use proposed API');
});

it('write', async () => {
Expand Down
2 changes: 1 addition & 1 deletion test/api/Terminal.api.ts
Expand Up @@ -35,7 +35,7 @@ describe('API Integration Tests', function(): void {
await openTerminal(page, { allowProposedApi: false });
await page.evaluate(`
try {
window.term.buffer;
window.term.markers;
} catch (e) {
window.throwMessage = e.message;
}
Expand Down