You are here

public function ViewsUpgradeTestCase::testUpgradeImport in Views (for Drupal 7) 7.3

Tests a import via ui.

To ensure the general functionality, the recent comments view from drupal6 is used.

File

tests/views_upgrade.test, line 118
Definition of ViewsUpgradeTestCase.

Class

ViewsUpgradeTestCase
Try to test the upgrade path of all conversions.

Code

public function testUpgradeImport() {
  $admin_user = $this
    ->drupalCreateUser(array(
    'administer views',
    'administer site configuration',
    'use PHP for settings',
  ));
  $this
    ->drupalLogin($admin_user);
  $edit = array(
    'view' => $this
      ->viewUpgradeImport(),
  );
  $this
    ->drupalPost('admin/structure/views/import', $edit, t('Import'));
  $this
    ->assertText('Recent comments');
}