Tests translation deletion.
protected function assertTranslationDeletion() {
// Confirm and delete a translation.
$langcode = 'fr';
$entity = entity_load($this->entityType, $this->entityId, TRUE);
$this
->drupalPost($langcode . '/' . $this->controller
->getEditPath($entity), array(), t('Delete translation'));
$this
->drupalPost(NULL, array(), t('Delete'));
$entity = entity_load($this->entityType, $this->entityId, TRUE);
if ($this
->assertTrue(is_object($entity), 'Entity found')) {
$translations = $entity
->getTranslationLanguages();
$this
->assertTrue(count($translations) == 2 && empty($translations[$langcode]), 'Translation successfully deleted.');
}
}