Comments

naveenvalecha created an issue. See original summary.

naveenvalecha’s picture

Version: 8.4.x-dev » 8.5.x-dev

Drupal 8.4.0-alpha1 will be released the week of July 31, 2017, which means new developments and disruptive changes should now be targeted against the 8.5.x-dev branch. For more information see the Drupal 8 minor version schedule and the Allowed changes during the Drupal 8 release cycle.

vaplas’s picture

Status: Active » Needs review
FileSize
6.62 KB

This patch covert:

  • ConfigTranslationUiTest
  • ConfigTranslationCacheTest

One js part detected:

+++ b/core/modules/config_translation/tests/src/Functional/ConfigTranslationUiTest.php
@@ -588,13 +590,6 @@ public function testSourceAndTargetLanguage() {
-    // Assert contextual link related to views.
-    $ids = ['entity.view.edit_form:view=frontpage:location=page&name=frontpage&display_id=page_1'];
-    $response = $this->renderContextualLinks($ids, 'node');
-    $this->assertResponse(200);
-    $json = Json::decode($response);
-    $this->assertTrue(strpos($json[$ids[0]], 'Translate view'), 'Translate view contextual link added.');

+++ b/core/modules/config_translation/tests/src/FunctionalJavascript/ConfigTranslationUiTest.php
@@ -0,0 +1,41 @@
+class ConfigTranslationUiTest extends JavascriptTestBase {
...
+    $this->drupalGet('node');
+    $contextualLinks = $this->assertSession()->waitForElement('css', '.contextual-links');
+    $link = $contextualLinks->findLink('Translate view');
+    $this->assertNotNull($link, 'Translate view contextual link added.');

No changes for ConfigTranslationInstallTest, because we can to do it only after #2907728: Installer: Convert system functional tests to phpunit. Current patch from dawehner (see post #3) is already enough for convert ConfigTranslationInstallTest, but looks like not enough for other system Installer* tests :(

Postponed?

Status: Needs review » Needs work

The last submitted patch, 4: 2888905-4.patch, failed testing. View results

vaplas’s picture

Status: Needs work » Needs review
FileSize
6.63 KB

CS fix.

Lendude’s picture

Status: Needs review » Reviewed & tested by the community
+++ b/core/modules/config_translation/tests/src/Functional/ConfigTranslationUiTest.php
@@ -1155,17 +1151,17 @@ protected function assertDisabledTextarea($id) {
-    $passed = $this->assertTrue($textarea instanceof \SimpleXMLElement, SafeMarkup::format('Disabled field @id exists.', [
...
-    $passed = $passed && $this->assertEqual((string) $textarea, $expected, SafeMarkup::format('Disabled textarea @id hides text in an inaccessible text format.', [
...
-    return $passed && $this->assertFalse($select, SafeMarkup::format('Field @id does not exist.', [

This $passed variable is removed. Took another look and that indeed doesn't seem to serve any purpose anymore, so that's good.

No need to postpone on the installer conversion issue. I think we will just do a cross-module update of all the installer tests once we get that running, like we did for the update tests.

This looks good, nice work as always @vaplas!

Lendude’s picture

Issue summary: View changes

Lets remove ConfigTranslationInstallTest from the scope here.

catch’s picture

Title: Convert ConfigTranslationInstallTest & ConfigTranslationUiTest WTB to JTB & BTB for config_translation module » ConvertConfigTranslationUiTest WTB to JTB & BTB for config_translation module
catch’s picture

Version: 8.5.x-dev » 8.4.x-dev
Status: Reviewed & tested by the community » Fixed

Committed/pushed to 8.5.x and cherry-picked to 8.4.x. Thanks!

  • catch committed 8145b33 on 8.5.x
    Issue #2888905 by vaplas, Lendude: ConvertConfigTranslationUiTest WTB to...

  • catch committed 459f35a on 8.4.x
    Issue #2888905 by vaplas, Lendude: ConvertConfigTranslationUiTest WTB to...

Status: Fixed » Closed (fixed)

Automatically closed - issue fixed for 2 weeks with no activity.