You are here

function LocaleExportFunctionalTest::testExportTranslationTemplateFile in Drupal 7

Test exportation of translation template file.

File

modules/locale/locale.test, line 1365
Tests for locale.module.

Class

LocaleExportFunctionalTest
Functional tests for the export of translation files.

Code

function testExportTranslationTemplateFile() {

  // Get the translation template file.
  // There are two 'Export' buttons on this page, but it somehow works.  It'd
  // be better if we could use the submit button id like documented but that
  // doesn't work.
  $this
    ->drupalPost('admin/config/regional/translate/export', array(), t('Export'));

  // Ensure we have a translation file.
  $this
    ->assertRaw('# LANGUAGE translation of PROJECT', 'Exported translation template file.');
}