Skip to content

Commit

Permalink
Accept unknown events in tests - addresses problem on opensuse
Browse files Browse the repository at this point in the history
  • Loading branch information
andersfugmann committed Mar 16, 2024
1 parent 1032b31 commit 7cca40d
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions zmq/test/zmq_test.ml
Original file line number Diff line number Diff line change
Expand Up @@ -107,6 +107,9 @@ let test_monitor () =
let rec receive_event ~end_time =
match Zmq.Monitor.recv ~block:false socket with
| event -> Zmq.Monitor.string_of_event event
| exception Invalid_argument(s) ->
Printf.eprintf "Warning: Invalid_argument: %s\n" s;
receive_event ~end_time
| exception Unix.Unix_error(Unix.EAGAIN, _, _) when end_time > (Unix.gettimeofday ()) ->
sleep 10;
receive_event ~end_time
Expand Down

0 comments on commit 7cca40d

Please sign in to comment.