Newer
Older
minerva / Userland / Libraries / LibJS / Tests / functions / function-missing-arg.js
@minerva minerva on 13 Jul 218 bytes Initial commit
test("basic functionality", () => {
    function foo(a, b) {
        return a + b;
    }

    expect(foo()).toBeNaN();
    expect(foo(1)).toBeNaN();
    expect(foo(2, 3)).toBe(5);
    expect(foo(2, 3, 4)).toBe(5);
});