The JCR spec says the following about Node.setProperty:
Some repositories may allow P to be dynamically re-bound to a different
property definition (based for example, on the new value being of a different
type than the original value) while other repositories may not allow such
However, the current TCK requires the implementation to keep the definition of the existing property.