Fix reflection warnings and extra tests