/*
 * Copyright (c) 2024 Huawei Device Co., Ltd.
 * Licensed under the Apache License, Version 2.0 (the "License");
 * you may not use this file except in compliance with the License.
 * You may obtain a copy of the License at
 *
 *     http://www.apache.org/licenses/LICENSE-2.0
 *
 * Unless required by applicable law or agreed to in writing, software
 * distributed under the License is distributed on an "AS IS" BASIS,
 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
 * See the License for the specific language governing permissions and
 * limitations under the License.
 */
import b from 'assert';
// Only use for testing importEqualsDeclaration in toplevel
import c = require('fs');
export import m = require('fs');
module d {
    export module Y {
        export interface Z {
            a: number;
        }
    }
    export interface Y {
        b: string;
    }
}
let a: d.Y.Z = { a: 1 };
b(a.a === 1);
let e: d.Y = { b: "1" };
b(e.b === "1");
module A {
    export module B {
        export class C {
            c: boolean = true;
        }
    }
}
var f: A.B.C = new A.B.C();
b(f.c === true);
module g {
    export namespace N {
        export module M2 {
            export interface I {
                d: number;
            }
        }
    }
}
let h: g.N.M2.I = { d: 2 };
b(h.d === 2);
type A = number;
declare const i: number;
declare namespace j {
    export { A };
}
let k: j.A = 3;
b(k === 3);
namespace l {
    namespace n {
        export var temp3: string = "test-importEqualsDeclaration";
    }
    import o = n.temp3;
    export import temp5 = n.temp3;
    b(o === "test-importEqualsDeclaration");
    b(temp5 === "test-importEqualsDeclaration");
}
namespace l {
    b(temp5 === "test-importEqualsDeclaration");
}
b(l.temp5 === "test-importEqualsDeclaration");
export {};
