Implements deep cloning of nodes

Adds more test (mostly cloning related).