-
Notifications
You must be signed in to change notification settings - Fork 36
Expand file tree
/
Copy pathSubtitlesTest.res.mjs
More file actions
63 lines (59 loc) · 1.75 KB
/
SubtitlesTest.res.mjs
File metadata and controls
63 lines (59 loc) · 1.75 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
// Generated by ReScript, PLEASE EDIT WITH CARE
import * as Test from "rescript-test/src/Test.res.mjs";
import * as Assert from "./Assert.res.mjs";
import * as Subtitles from "../src/screens/editor/Subtitles.res.mjs";
Test.test("resizeChunks", (function () {
var value = Subtitles.resizeChunks([[
{
id: 0,
text: "Hello",
isInProgress: undefined,
timestamp: [
0.0,
1.0
]
},
{
id: 1,
text: " world",
isInProgress: undefined,
timestamp: [
1.0,
2.0
]
},
{
id: 1,
text: " It's",
isInProgress: undefined,
timestamp: [
2.0,
3.0
]
},
{
id: 1,
text: " me",
isInProgress: undefined,
timestamp: [
3.0,
4.0
]
},
{
id: 1,
text: " Mario",
isInProgress: undefined,
timestamp: [
4.0,
5.0
]
}
]], 10);
Assert.stringEqual(undefined, value[0].text.trim(), "Hello world");
Assert.stringEqual(undefined, value[1].text.trim(), "It's me");
Assert.stringEqual(undefined, value[2].text.trim(), "Mario");
}));
export {
}
/* Not a pure module */