Rails 4.0 upgrade

Fixed more test cases.
Update configuration files with new properties names.
revert some commit made by mistake (change the port).