I know there are already many questions here on this topic, but I've had trouble finding exactly what I need.
We're a small team of developers currently using SVN but soon to be making a switch to Git. We are used to checking in changes and pushing to the live website throughout the day but currently lack any formal testing procedures, which is something we'd like to add. The way I'm used to doing this with SVN is:
- develop in a personal test environment
- check in your changes
- send the current repository files to a global (production-like) testing webserver, and test
- send the current repository files to the live webservers
This obviously can create some problems, especially if communication is not good. I've experienced times when untested changes have gone live and that's something we'd definitely like to avoid.
What I'm envisioning is a master Git repository that holds the tested code that is running on the live servers. Then have a clone of that repository that is used to test revisions. I'd like to have a script that is responsible for pulling changes from the requesting developer, putting them in a branch on the test repository, and running some automated tests to make sure nothing major is broken. When that all checks out, that branch can be merged and pushed up to the master and out to the live servers.
I'd like to hear any comments about this possible workflow and any suggestions for improvement or how to do it differently. Also, any specifics on how to set this up would also be appreciated. Thanks!
EDIT: I've used the above method for a while now and it's worked out pretty well.