~ubuntu-branches/debian/sid/ocaml/sid

« back to all changes in this revision

Viewing changes to testsuite/lib/testing.mli

  • Committer: Bazaar Package Importer
  • Author(s): Stéphane Glondu
  • Date: 2011-04-21 21:35:08 UTC
  • mfrom: (1.1.11 upstream) (12.1.14 sid)
  • Revision ID: james.westby@ubuntu.com-20110421213508-kg34453aqmb0moha
* Fixes related to -output-obj with g++ (in debian/patches):
  - add Declare-primitive-name-table-as-const-char
  - add Avoid-multiple-declarations-in-generated-.c-files-in
  - fix Embed-bytecode-in-C-object-when-using-custom: the closing
    brace for extern "C" { ... } was missing in some cases

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
(***********************************************************************)
 
2
(*                                                                     *)
 
3
(*                           Objective Caml                            *)
 
4
(*                                                                     *)
 
5
(*             Pierre Weis, projet Cristal, INRIA Rocquencourt         *)
 
6
(*                                                                     *)
 
7
(*  Copyright 2006 Institut National de Recherche en Informatique et   *)
 
8
(*  en Automatique.  All rights reserved.  This file is distributed    *)
 
9
(*  under the terms of the Q Public License version 1.0.               *)
 
10
(*                                                                     *)
 
11
(***********************************************************************)
 
12
 
 
13
(* $Id: testing.mli,v 1.1 2006/01/12 12:52:14 weis Exp $ *)
 
14
 
 
15
(* Testing auxilliaries. *)
 
16
 
 
17
val test : bool -> unit;;
 
18
(** [test e] tests that [e] evaluates to [true]. *)
 
19
val failure_test : ('a -> 'b) -> 'a -> string -> bool;;
 
20
(** [failure_test f x s] tests that [f x] raises the exception [Failure s]. *)
 
21
 
 
22
val test_raises_some_exc : ('a -> 'b) -> 'a -> bool;;
 
23
(** [test_raises_some_exc f x] tests that [f x] raises an exception. *)
 
24
 
 
25
val test_raises_this_exc : exn -> ('a -> 'b) -> 'a -> bool;;
 
26
(** [test_raises_this_exc exc f x] tests that [f x]
 
27
    raises the exception [exc]. *)
 
28
 
 
29
val test_raises_exc_p : (exn -> bool) -> ('a -> 'b) -> 'a -> bool;;
 
30
(** [test_raises_exc_p p f x] tests that [f x] raises an exception that
 
31
    verifies predicate [p]. *)
 
32
 
 
33
val scan_failure_test : ('a -> 'b) -> 'a -> bool;;
 
34
(** [scan_failure_test f x] tests that [f x] raises [Scanf.Scan_failure]. *)