hmmm.. sounds like a misconfiguration. the message you saw meant that apache was unable to interpret the file you are requesting, test.php in this case, and it asked you to download it.
check to make sure that you setup php on your apache correctly. also i assume you are calling the page from http://127.0.0.1/test.php right? A common mistake is to simply open the file using File->open and then open test.php. also make sure that you have your extensions/MIME types set up correctly such that any file ending in .php (or whatever the extension you choose it to be-common choices are .phtml, .php4, .php3 etc.) are properly handled by the php module. at least in IIS I can tell you that it should say something like c:\phpdir\php.exe %s %s
here's a test.php you can use
<?php
echo "Hello world";
$var = 5;
$total = $var + 5;
echo "<br>$total";
?>
It should produce something like
Hello world
15
good luck.