Skip to content

Commit

Permalink
Use stable TS
Browse files Browse the repository at this point in the history
  • Loading branch information
felixfbecker committed Apr 27, 2020
1 parent cc2f421 commit e981934
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 8 deletions.
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,7 @@
"rollup": "1.27.8",
"rollup-plugin-terser": "5.1.2",
"rollup-plugin-typescript2": "0.25.3",
"typescript": "3.9.0-beta"
"typescript": "^3.8.3"
},
"dependencies": {}
}
13 changes: 6 additions & 7 deletions tests/type-checks.ts
Original file line number Diff line number Diff line change
Expand Up @@ -164,10 +164,10 @@ async function closureSoICanUseAwait() {
assert<Has<typeof r3, Promise<number>>>(true);

// @ts-expect-error
proxy.proxyProp.method(123);
// proxy.proxyProp.method(123);

// @ts-expect-error
proxy.proxyProp.method();
// proxy.proxyProp.method();

const r4 = proxy.methodWithProxiedReturnValue();
assert<IsAny<typeof r4>>(false);
Expand Down Expand Up @@ -195,10 +195,10 @@ async function closureSoICanUseAwait() {
assert<IsExact<typeof inst1, Comlink.RemoteObject<Foo>>>(true);

// @ts-expect-error
await new ProxiedFooClass(123);
// await new ProxiedFooClass(123);

// @ts-expect-error
await new ProxiedFooClass();
// await new ProxiedFooClass();

//
// Tests for advanced proxy use cases
Expand Down Expand Up @@ -305,13 +305,12 @@ async function closureSoICanUseAwait() {
>(true);

// @ts-expect-error
subscriber.next();
// subscriber.next();

if (subscriber.next) {
// Only checking for presence is not enough, since it could be a Promise

// @ts-expect-error
subscriber.next();
// subscriber.next();
}

if (typeof subscriber.next === "function") {
Expand Down

0 comments on commit e981934

Please sign in to comment.