for ($i = 1;
$i < 5;
$i++
) { $row =
$id_map->
getRowBySource(['tid' =>
$i]);
$new_hash[$i] =
$row['hash'
];
} $this->
assertNotEquals($original_hash[1
],
$new_hash[1
]);
$this->
assertEquals($original_hash[2
],
$new_hash[2
]);
$this->
assertNotEquals($original_hash[3
],
$new_hash[3
]);
$this->
assertEquals($original_hash[4
],
$new_hash[4
]);
// Item with name changes should be updated.
$this->
assertTermExists('name', 'Item 1 updated'
);
$this->
assertTermDoesNotExist('name', 'Item 1'
);
// Item without name changes should not be updated.
$this->
assertTermExists('name', 'Item 2'
);
// Item with field changes should be updated.
$this->
assertTermExists('description', 'Text item 3 updated'
);
$this->
assertTermDoesNotExist('description', 'Text item 3'
);
// Item without field changes should not be updated.
$this->
assertTermExists('description', 'Text item 4'
);