Displaying 15 results from an estimated 15 matches for "assert_failur".
Did you mean:
assert_failure
2018 Aug 20
0
[PATCH 4/4] mltools: JSON: unify JSON_parser type with JSON.json_t.
...(match value with | JSON_parser_object _ -> true | _ -> false)
+ (match value with | JSON.Dict _ -> true | _ -> false)
let assert_is_string exp = function
- | JSON_parser_string s -> assert_equal_string exp s
+ | JSON.String s -> assert_equal_string exp s
| _ as v -> assert_failure (type_mismatch_string "string" v)
let assert_is_number exp = function
- | JSON_parser_number n -> assert_equal_int64 exp n
- | JSON_parser_double d -> assert_equal_int64 exp (Int64.of_float d)
+ | JSON.Int i -> assert_equal_int64 exp i
+ | JSON.Float f -> assert_equal_in...
2018 Aug 22
3
[PATCH v2 0/2] mltools: JSON: unify JSON & JSON parser.
v2:
- Added back the null value.
- Reran the tests.
Rich.
2018 Aug 20
6
[PATCH 0/4] mltools: JSON unification
An evolution of:
https://www.redhat.com/archives/libguestfs/2018-August/msg00155.html
2019 Jan 23
2
[supermin PATCH 1/2] rpm: extend the Multiple_matches exception
Add the package that raised the issue, so it can be used to provide
better diagnostic.
---
src/librpm-c.c | 15 ++++++++++-----
src/librpm.ml | 4 ++--
src/librpm.mli | 2 +-
3 files changed, 13 insertions(+), 8 deletions(-)
diff --git a/src/librpm-c.c b/src/librpm-c.c
index 3bd25a2..75ca4d7 100644
--- a/src/librpm-c.c
+++ b/src/librpm-c.c
@@ -66,10 +66,15 @@ librpm_handle_closed (void)
}
2018 Aug 17
0
[PATCH v3 1/4] mltools: Rename Yajl module as JSON_parser and move to common/mltools.
...(match value with | Yajl_object _ -> true | _ -> false)
+ (match value with | JSON_parser_object _ -> true | _ -> false)
let assert_is_string exp = function
- | Yajl_string s -> assert_equal_string exp s
+ | JSON_parser_string s -> assert_equal_string exp s
| _ as v -> assert_failure (type_mismatch_string "string" v)
let assert_is_number exp = function
- | Yajl_number n -> assert_equal_int64 exp n
- | Yajl_double d -> assert_equal_int64 exp (Int64.of_float d)
+ | JSON_parser_number n -> assert_equal_int64 exp n
+ | JSON_parser_double d -> assert_equa...
2019 Jan 23
0
[supermin PATCH 2/2] Print Librpm.Multiple_matches exceptions
...s" msg
+ | Librpm.Multiple_matches (package, count) -> (* from librpm *)
+ error "RPM error: %d occurrences for %s" count package
| Invalid_argument msg -> (* probably should never happen *)
error "internal error: invalid argument: %s" msg
| Assert_failure (file, line, char) -> (* should never happen *)
--
2.20.1
2018 Aug 17
8
[PATCH v3 4/4] v2v: Add --print-estimate option to print copy size
I rethought this again, as I think that it's a dangerous assumption to
bake qemu-img measure output into our API.
This patch series runs qemu-img measure behind the scenes, but then
parses the output and sums it to a single number which we print.
Doing that required a bit of reworking, moving the Jansson [JSON
parser] bindings from virt-builder into the common directory and
a couple of other
2015 Sep 07
5
[PATCH 0/4 v3] builder: support for Simple Streams metadata
Hi,
this series adds a basic support for Simple Streams v1.0 metadata
files. This makes it possible to create a repository .conf files with
[cirros]
uri=http://download.cirros-cloud.net
format=simplestreams
to read the latest version of each CirrOS image.
Thanks,
Pino Toscano (4):
builder: add non-int revisions
builder: add simple libyajl binding
build: expose HAVE_YAJL to automake
2019 Jan 11
3
[PATCH 1/3] mlstdutils: add a very simple test for Std_utils.which
...ringlist = assert_equal ~printer:(fun x -> "(" ^ (String.escaped (String.concat "," x)) ^ ")")
let assert_equal_stringpair = assert_equal ~printer:(fun (x, y) -> sprintf "%S, %S" x y)
+let assert_nonempty_string str =
+ if str = "" then
+ assert_failure (sprintf "Expected empty string, got '%s'" str)
+let assert_raises_executable_not_found exe =
+ assert_raises (Executable_not_found exe) (fun () -> which exe)
(* Test Std_utils.int_of_X and Std_utils.X_of_int byte swapping
* functions.
@@ -140,6 +145,12 @@ let test_strin...
2016 Feb 18
0
[PATCH 3/3] Add and use an helper error function
...uot; msg;
- exit 1
+ error "failure: %s" msg
| Invalid_argument msg -> (* probably should never happen *)
- eprintf "supermin: internal error: invalid argument: %s\n" msg;
- exit 1
+ error "internal error: invalid argument: %s" msg
| Assert_failure (file, line, char) -> (* should never happen *)
- eprintf "supermin: internal error: assertion failed at %s, line %d, char %d\n" file line char;
- exit 1
+ error "internal error: assertion failed at %s, line %d, char %d"
+ file line char
| Not_found ->...
2016 Feb 18
4
[PATCH 0/3] supermin: miscellaneous cleanups
Hi,
few cleanups in the supermin codebase; no actual functional change.
Thanks,
--
Pino Toscano (3):
ext2: simplify tracking of visited modules
utils: remove unused run_python function
Add and use an helper error function
src/build.ml | 20 +++++-----------
src/dpkg.ml | 4 +---
src/ext2_initrd.ml | 10 ++++----
src/kernel.ml | 27
2014 Mar 11
21
[PATCH v2 00/18] Add discard support.
This still isn't working at the moment. See:
http://marc.info/?t=139457409300003&r=1&w=2
This set of patches:
- Adds new APIs to support discard in libguestfs.
- Adds discard support to virt-format.
- Adds discard support to virt-sysprep.
- Implements virt-sparsify --in-place.
Rich.
2015 May 15
5
[PATCH 0/4] Only tell people to use -v -x when reporting bugs if they're not using those flags.
.. and a lot of refactoring.
https://bugzilla.redhat.com/show_bug.cgi?id=1167623
Rich.
2015 May 15
6
[PATCH v2 0/4] Only tell people to use -v -x when reporting bugs if they're not using those flags.
https://bugzilla.redhat.com/show_bug.cgi?id=1167623
2014 Feb 25
2
[PATCH supermin v4] Supermin 5 rewrite.
...g -> (* from failwith/failwithf *)
+ eprintf "supermin: failure: %s\n" msg;
+ exit 1
+ | Invalid_argument msg -> (* probably should never happen *)
+ eprintf "supermin: internal error: invalid argument: %s\n" msg;
+ exit 1
+ | Assert_failure (file, line, char) -> (* should never happen *)
+ eprintf "supermin: internal error: assertion failed at %s, line %d, char %d\n" file line char;
+ exit 1
+ | Not_found -> (* should never happen *)
+ eprintf "supermin: internal error: Not_found...