some fixes for static calls and a test