Publishing YouTube app on Windows Phone requires Google to put extra effort into developing an app for a completely new platform which I assume requires lot of engineering effort.
Selling Chromecast on Amazon probably does not cost Amazon any extra engineering effort. So, I do not believe that the two situations are equivalent.
Sure, since Microsoft didn’t show any ads for google. I think Microsoft might be pissed if google started hosting free copies of their software on their servers.