function OpenIDFunctionalTestCase::testDelete

Test deleting an OpenID identity from a user's profile.

File

modules/openid/openid.test, line 229

Class

OpenIDFunctionalTestCase
Test discovery and login using OpenID

Code

function testDelete() {
    $this->drupalLogin($this->web_user);
    // Add identity to user's profile.
    $identity = url('openid-test/yadis/xrds', array(
        'absolute' => TRUE,
    ));
    $this->addIdentity($identity);
    $this->assertText($identity, 'Identity appears in list.');
    // Delete the newly added identity.
    $this->clickLink(t('Delete'));
    $this->drupalPost(NULL, array(), t('Confirm'));
    $this->assertText(t('OpenID deleted.'), 'Identity deleted');
    $this->assertNoText($identity, 'Identity no longer appears in list.');
}

Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.