Skip to content

Commit 51d6aef

Browse files
committed
Add failing test.
1 parent f83fa1c commit 51d6aef

File tree

2 files changed

+22
-0
lines changed

2 files changed

+22
-0
lines changed

tests/Issue44.hx

Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
import js.Browser.*;
2+
import coconut.vdom.Renderer.*;
3+
4+
@:asserts
5+
class Issue44 {
6+
public static var clicks = 0;
7+
public static var computations = 0;
8+
public function new() {}
9+
public function run() {
10+
var root = document.createElement("div");
11+
document.body.appendChild(root);
12+
13+
var child = root;
14+
15+
try mount(root, hxx('<div ref={v -> child = v} style=${{ "--foo": 123 }}/>'))
16+
catch (_) {};
17+
18+
asserts.assert(child.style.getPropertyValue('--foo') == "123");
19+
return asserts.done();
20+
}
21+
}

tests/RunTests.hx

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -16,6 +16,7 @@ class RunTests {
1616
new RunTests(),
1717
new Issue32(),
1818
new Issue37(),
19+
new Issue44(),
1920
])).handle(Runner.exit);
2021
}
2122

0 commit comments

Comments
 (0)