Fix timestamp exports and imports; refine unit tests