Adding deprecation value to replace function

@cpennington @flowerhack @dianakhuang 
The replace function wasn't transmitting the deprecation property to the new object. This should fix that.

I'm 100% sure where I should put the unit test for this. Suggestions?
I may not be following your logic—what exactly are the id() comparisons here supposed to test?