mirror of
https://github.com/hanzoai/babel.git
synced 2026-09-24 16:56:45 +00:00
* breaking(partial-app): require version option * chore: update yarn.lock * test: add case for empty version * update artifacts
19 lines
344 B
JavaScript
19 lines
344 B
JavaScript
function add(a, b) {
|
|
return a + b;
|
|
}
|
|
|
|
function square(x){
|
|
return x * x;
|
|
}
|
|
|
|
const foo = add(?, 1);
|
|
const bar = square(?);
|
|
|
|
expect(bar(foo(2))).toEqual(9);
|
|
expect(foo(2)).toEqual(3);
|
|
expect(bar(4)).toEqual(16);
|
|
expect(foo.length).toEqual(1);
|
|
expect(foo.name).toEqual("add");
|
|
expect(bar.length).toEqual(1);
|
|
expect(bar.name).toEqual("square");
|