Don't use report_warning for reporting warnings

In tests warning is converted to error