If the sounds test fails in DXDIAG, then either the volume is turned off, or the speakers are not connected to the correct port, or you do not have the correct speaker configuration in Windows, or the driver loaded is not the correct driver, or the sound card has gone bad, or you have another sound card device installed which Windows is using instead.
It could also be any combination of the above.