Remember, the Portuguese had mapped the whole west coast of Australia centuries before Cook got there. He went there to map the *east* coast, and succeeded mostly because he got inside the Great Barrier Reef and spent quite a while trying to find his way back out. :-).
His official mission was to go to Tahiti to chart a transit of (Venus? Mercury?) across the sun. After that, he unsealed secret orders that sent him south to find “the southern continent” that everyone knew was there. He found New Zealand. Not thinking that was good enough, we cut over to Australia to do the west coast mapping thing. Discovered Sydney (”Botany Bay”), and went north from there.
“Remember, the Portuguese had mapped the whole west coast of Australia centuries before Cook got there”
It was the Dutch not the Portuguese