def parse_result(self, data):
        # typedef struct {
        #   uint8_t numBytes;                   // Number of bytes in buffer now
        # } YSM_BUFFER_LOAD_RESP;
        count = ord(data[0])
        if self.offset == 0:
            # if offset was 0, the buffer was reset and
            # we can verify the length returned
            if count != self.num_bytes:
                raise pyhsm.exception.YHSM_Error("Incorrect number of bytes in buffer (got %i, expected %i)" \
                                               % (self.num_bytes, count))
        return count
Test searching for None.
dataset/ETHPy150Open Yubico/python-pyhsm/pyhsm/buffer_cmd.py/YHSM_Cmd_Buffer_Random_Load.parse_result--crossover with--dataset/ETHPy150Open vmalloc/mongomock/tests/test__mongomock.py/MongoClientCollectionTest.test__find_notequal_by_value