finished unmarshalling. added tests