Every Debian distribution is managed by the /etc/apt/sources.list file.
This file allows you to specify whether you want your distribution to run as a stable, testing or unstable distribution.
To view or edit this file from the command line you need to type:
test:~# pico /etc/apt/sources.list
After editing the file and saving it, you need to run the following command:
test:~# apt-get update
which rebuilds the package database to reflect your newest sources.list
Once this is done, you can upgrade everything on your system to the latest versions by running the following command:
test:~# apt-get dist-upgrade
If you want to flip from one distribution to the other, just modify the sources.list file, and run the following commands:
test:~# apt-get update
test:~# apt-get dist-upgrade
That is all there is to it!