Chris@0: siteDirectory . '/files/translations', 0777, TRUE); Chris@0: file_put_contents(\Drupal::root() . '/' . $this->siteDirectory . '/files/translations/drupal-8.0.0.ar.po', "msgid \"\"\nmsgstr \"\"\nmsgid \"Save and continue\"\nmsgstr \"Save and continue Arabic\""); Chris@0: Chris@0: parent::setUpLanguage(); Chris@0: // After selecting a different language than English, all following screens Chris@0: // should be translated already. Chris@0: $elements = $this->xpath('//input[@type="submit"]/@value'); Chris@0: $this->assertEqual((string) current($elements), 'Save and continue Arabic'); Chris@0: $this->translations['Save and continue'] = 'Save and continue Arabic'; Chris@0: Chris@0: // Verify that language direction is right-to-left. Chris@0: $direction = (string) current($this->xpath('/html/@dir')); Chris@0: $this->assertEqual($direction, 'rtl'); Chris@0: } Chris@0: Chris@0: /** Chris@0: * Confirms that the installation succeeded. Chris@0: */ Chris@0: public function testInstalled() { Chris@0: $this->assertUrl('user/1'); Chris@0: $this->assertResponse(200); Chris@0: } Chris@0: Chris@0: }