// E2E 测试：path 模块
import * as path from "path";

function main(): number {
    // Test path.join()
    let joined = path.join("a", "b", "c");
    print("join: " + joined);

    // Test path.dirname()
    let dir = path.dirname("/a/b/c");
    print("dirname: " + dir);

    // Test path.basename()
    let base = path.basename("/a/b/c.txt");
    print("basename: " + base);

    // Test path.extname()
    let ext = path.extname("/a/b/c.txt");
    print("extname: " + ext);

    if (joined != "" && dir != "" && base != "" && ext != "") {
        return 1;
    }
    return 0;
}
