Add Term::setDefault and a simple serialization test