add unit tests for AVUtils methods, fix compiler warnings