Add tests for key stream.