As with most products, companies need a way to make promises to consumers about what's in the products. The only way the consumers will believe those promises is if the consequences for lying are severe. Clearly room for improvement here, maybe some of these 3rd party certification labs can start putting their seals on medications too.
The article mentions that medication from China isn't part of an FDA approved supply chain, but as a consumer I don't really care about that. I'd rather have mass spectrometry data on the side of the tin than the FDA's blessing.