make stubapi a pointer for easier test verification