Skip to content

Commit 203c1c8

Browse files
committed
chore: Test build failure
1 parent 4bb4e40 commit 203c1c8

File tree

2 files changed

+9
-9
lines changed

2 files changed

+9
-9
lines changed

src/settings.js

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -163,9 +163,12 @@ function caml_binaryen_clear_pass_arguments() {
163163
//Provides: caml_binaryen_has_pass_to_skip
164164
//Requires: Binaryen
165165
//Requires: caml_jsstring_of_string
166+
//Requires: caml_js_to_bool
166167
function caml_binaryen_has_pass_to_skip(pass) {
167-
return Binaryen.hasPassToSkip(
168-
caml_jsstring_of_string(pass)
168+
return caml_js_to_bool(
169+
Binaryen.hasPassToSkip(
170+
caml_jsstring_of_string(pass)
171+
)
169172
);
170173
}
171174

test/test.ml

Lines changed: 4 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -55,14 +55,11 @@ let _ = assert (Settings.get_optimize_stack_ir () == true)
5555
let _ = Settings.set_optimize_stack_ir false
5656

5757
(* Testing pass_argument *)
58+
let _ = assert (Settings.get_pass_argument "theKey" = None)
5859
let _ = Settings.set_pass_argument "theKey" "theValue"
59-
let _ = Settings.get_pass_argument "theKey" = "theValue"
60-
let _ = Settings.set_pass_argument "theKey" "theValue2"
61-
let _ = Settings.get_pass_argument "theKey" = "theValue2"
62-
63-
let _ =
64-
Settings.clear_pass_arguments
65-
() (* Note: there is no way to test this currently *)
60+
let _ = assert (Settings.get_pass_argument "theKey" = Some "theValue")
61+
let _ = Settings.clear_pass_arguments ()
62+
let _ = assert (Settings.get_pass_argument "theKey" = None)
6663

6764
(* Testing skip_pass *)
6865
let _ = assert (Settings.has_pass_to_skip "thePass" == false)

0 commit comments

Comments
 (0)