Plan for switching to T-mobile?

Does anyone see any problems with this plan?

I am currently on Sprint and I am currently able to upgrade my phone with a new 2-year agreement. I was thinking about doing so and getting a nice phone for like $199 or whatever. I would then sell that phone on Ebay, go over to T-mobile, trade in my current device and use the proceeds to purchase a Moto X at full price.

Does anyone know whether T-mobile cares which device you trade in? I currently have a Galaxy Nexus and it is in pretty decent shape.