I've purchased a YongNuo flash several years ago and it stopped working properly only after a few months. That said, I've heard their quality has gotten much better since then.

If you really want to save the money and get the YongNuo version, I'd suggest purchasing from an Amazon seller with a generous return policy (just in case). Otherwise, the Canon version is the gold standard and comes with a pretty good warranty.