improved warning output, updated tests