summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--sid_test.ml23
1 files changed, 11 insertions, 12 deletions
diff --git a/sid_test.ml b/sid_test.ml
index f9e3688..ec4913a 100644
--- a/sid_test.ml
+++ b/sid_test.ml
@@ -8,21 +8,20 @@ let () = Printexc.record_backtrace true ;;
*)
(* S-1-1-0-1-2-3-4-5-6-7-8-9-10-11-12-13-14 *)
-let max_sid = Stdint.(
+let max_sid =
Sid.create_unsafe
- [| Uint32.zero ; Uint32.one ; Uint32.of_int 2
- ; Uint32.of_int 3 ; Uint32.of_int 4 ; Uint32.of_int 5
- ; Uint32.of_int 6 ; Uint32.of_int 7 ; Uint32.of_int 8
- ; Uint32.of_int 9 ; Uint32.of_int 10 ; Uint32.of_int 11
- ; Uint32.of_int 12 ; Uint32.of_int 13 ; Uint32.of_int 14
+ [| U32.zero ; U32.one ; U32.of_int 2
+ ; U32.of_int 3 ; U32.of_int 4 ; U32.of_int 5
+ ; U32.of_int 6 ; U32.of_int 7 ; U32.of_int 8
+ ; U32.of_int 9 ; U32.of_int 10 ; U32.of_int 11
+ ; U32.of_int 12 ; U32.of_int 13 ; U32.of_int 14
|]
- Uint64.one
- )
+ U64.one
let create_ok () =
let w = Sid.WellKnown.everyone
and s =
- match Sid.create ~sa:[| Stdint.Uint32.zero |] Stdint.Uint64.one with
+ match Sid.create ~sa:[| U32.zero |] U64.one with
| None -> assert_failure "Sid.create failed for S-1-0"
| Some s -> s
in
@@ -31,8 +30,8 @@ let create_ok () =
(Sid.equal s w)
let create_fail () =
- let sas = Array.make 16 Stdint.Uint32.one in
- match Sid.create ~sa:sas Stdint.Uint64.zero with
+ let sas = Array.make 16 U32.one in
+ match Sid.create ~sa:sas U64.zero with
| None -> ()
| Some s -> assert_failure ("Sid.create succeeded on invalid sa array")
@@ -45,7 +44,7 @@ let unwrap_of_string s =
let sf_parse_ok () =
let s = unwrap_of_string "S-1-1-0"
- and z = Stdint.((Sid.create_unsafe [| Uint32.zero |] Uint64.one)) in
+ and z = Sid.create_unsafe [| U32.zero |] U64.one in
assert_bool
(Printf.sprintf "[%s] ≠ [%s]" (Sid.to_string s) (Sid.to_string z))
(Sid.equal s z);