Avoid warnings with tests enabled

cc @dinosaure