Add unit tests for constant-time set, xor and neg operations