Add another test
This commit is contained in:
parent
094f97e366
commit
f215ac94c2
|
@ -1,10 +1,10 @@
|
|||
tests/cases/conformance/ambient/declarations.d.ts(6,16): error TS5061: Pattern 'too*many*asterisks' can have at most one '*' character
|
||||
tests/cases/conformance/ambient/declarations.d.ts(10,16): error TS5061: Pattern 'too*many*asterisks' can have at most one '*' character
|
||||
|
||||
|
||||
==== tests/cases/conformance/ambient/user.ts (0 errors) ====
|
||||
///<reference path="declarations.d.ts" />
|
||||
import {foo} from "foobarbaz";
|
||||
foo(0);
|
||||
import {foo, baz} from "foobarbaz";
|
||||
foo(baz);
|
||||
|
||||
import {foos} from "foosball";
|
||||
|
||||
|
@ -12,6 +12,10 @@ tests/cases/conformance/ambient/declarations.d.ts(6,16): error TS5061: Pattern '
|
|||
declare module "foo*baz" {
|
||||
export function foo(n: number): void;
|
||||
}
|
||||
// Augmentations still work
|
||||
declare module "foo*baz" {
|
||||
export const baz: number;
|
||||
}
|
||||
|
||||
// Should be an error
|
||||
declare module "too*many*asterisks" { }
|
||||
|
|
|
@ -4,6 +4,10 @@
|
|||
declare module "foo*baz" {
|
||||
export function foo(n: number): void;
|
||||
}
|
||||
// Augmentations still work
|
||||
declare module "foo*baz" {
|
||||
export const baz: number;
|
||||
}
|
||||
|
||||
// Should be an error
|
||||
declare module "too*many*asterisks" { }
|
||||
|
@ -15,8 +19,8 @@ declare module "foos*" {
|
|||
|
||||
//// [user.ts]
|
||||
///<reference path="declarations.d.ts" />
|
||||
import {foo} from "foobarbaz";
|
||||
foo(0);
|
||||
import {foo, baz} from "foobarbaz";
|
||||
foo(baz);
|
||||
|
||||
import {foos} from "foosball";
|
||||
|
||||
|
@ -25,4 +29,4 @@ import {foos} from "foosball";
|
|||
"use strict";
|
||||
///<reference path="declarations.d.ts" />
|
||||
var foobarbaz_1 = require("foobarbaz");
|
||||
foobarbaz_1.foo(0);
|
||||
foobarbaz_1.foo(foobarbaz_1.baz);
|
||||
|
|
|
@ -2,6 +2,10 @@
|
|||
declare module "foo*baz" {
|
||||
export function foo(n: number): void;
|
||||
}
|
||||
// Augmentations still work
|
||||
declare module "foo*baz" {
|
||||
export const baz: number;
|
||||
}
|
||||
|
||||
// Should be an error
|
||||
declare module "too*many*asterisks" { }
|
||||
|
@ -13,7 +17,7 @@ declare module "foos*" {
|
|||
|
||||
// @Filename: user.ts
|
||||
///<reference path="declarations.d.ts" />
|
||||
import {foo} from "foobarbaz";
|
||||
foo(0);
|
||||
import {foo, baz} from "foobarbaz";
|
||||
foo(baz);
|
||||
|
||||
import {foos} from "foosball";
|
||||
|
|
Loading…
Reference in a new issue