Skip to content

Commit 875834c

Browse files
committed
relocate tests
1 parent 6abbae7 commit 875834c

File tree

3 files changed

+16
-11
lines changed

3 files changed

+16
-11
lines changed

jscomp/build_tests/react_ppx/src/alias_default_value_test.bs.js renamed to jscomp/test/alias_default_value_test.js

Lines changed: 9 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,13 +1,12 @@
1-
// Generated by ReScript, PLEASE EDIT WITH CARE
21
'use strict';
32

43

54
function Alias_default_value_test$C0(props) {
65
var b = props.b;
7-
b !== undefined ? b : 2;
6+
var b$1 = b !== undefined ? b : 2;
87
var a = props.a;
9-
a !== undefined ? a : 2;
10-
return null;
8+
var a$1 = a !== undefined ? a : 2;
9+
return a$1 + b$1 | 0;
1110
}
1211

1312
var C0 = {
@@ -16,7 +15,12 @@ var C0 = {
1615
};
1716

1817
function Alias_default_value_test$C1(props) {
19-
return null;
18+
var foo = props.foo;
19+
if (foo !== undefined) {
20+
return foo;
21+
} else {
22+
return "";
23+
}
2024
}
2125

2226
var C1 = {
Original file line numberDiff line numberDiff line change
@@ -1,18 +1,18 @@
1-
@@jsxConfig({version: 4})
1+
@@bs.config({
2+
flags: ["-bs-jsx", "4"],
3+
})
24

35
module C0 = {
46
let a = 1
57
@react.component
68
let make = (~a=2, ~b=a * 2) => {
7-
let _ = a + b
8-
React.null
9+
React.int(a + b)
910
}
1011
}
1112

1213
module C1 = {
1314
@react.component
1415
let make = (~foo as bar="") => {
15-
let _ = bar
16-
React.null
16+
React.string(bar)
1717
}
1818
}

0 commit comments

Comments
 (0)