if you pass on the variable as reference, you will always clear the original variable as well when you clear the new variable, that's the idea behind passing as reference
If you simply want to pass on the value of the $_SESSION['test'] variable, don't use the apmersand in front of $_SESSION['test']. Now you can clear the $_SESSION['test'] variable by using: