you migrate the files and database to your new domain, after that go to your database and run the SQL modifying the desired URL below:
UPDATE core_config_data SET value = 'http://urlteste.com.br/' WHERE path = 'web/unsecure/base_url';
UPDATE core_config_data SET value = 'http://urlteste.com.br/' WHERE path = 'web/secure/base_url';
TRUNCATE also makes the following tables:
log_url
log_url_info
log_visitor
log_visitor_info
After that clean the cache of your Magento which is in var/cache/* folder and test again.