iPhone 3G set time automatically?
&quot;Set Automatically&quot; takes the time from the cellular network. If you remove the SIM card (or just keep the phone in airplane mode with Wi-Fi enable), the time will never get updated.
From the iPhone User Guide (available in iTunes):

If iPhone is set to update the time automatically, it gets the correct time over the cellular network and updates it for the time zone you’re in.
Some carriers don’t support network time in all areas. If you’re traveling, iPhone may not be able to automatically set the local time.