The hardware doesn't care what it was designed for; it does what it's told. It is extremely plausible that capabilities which exist for testing purposes can also be exploited for running malware.
You can kill someone with a hammer, but that doesn't mean the hammer was designed for killing.