Make create_tree without base_tree work again

GitHub now sends an error when specifying an empty base_tree, so let's
not provide it at all if it's empty.
Fix tests for #282