projects
/
yaffs-website
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Updated all the contrib modules to their latest versions.
[yaffs-website]
/
web
/
modules
/
contrib
/
diff
/
src
/
Tests
/
DiffPluginTest.php
diff --git
a/web/modules/contrib/diff/src/Tests/DiffPluginTest.php
b/web/modules/contrib/diff/src/Tests/DiffPluginTest.php
index 67c683b383c85c535b3133dac170d073dca75f67..f01dc5fcc75d24fca14e74263bcd5324799ff2fd 100644
(file)
--- a/
web/modules/contrib/diff/src/Tests/DiffPluginTest.php
+++ b/
web/modules/contrib/diff/src/Tests/DiffPluginTest.php
@@
-5,6
+5,7
@@
namespace Drupal\diff\Tests;
use Drupal\comment\Tests\CommentTestTrait;
use Drupal\field\Entity\FieldConfig;
use Drupal\field\Entity\FieldStorageConfig;
use Drupal\comment\Tests\CommentTestTrait;
use Drupal\field\Entity\FieldConfig;
use Drupal\field\Entity\FieldStorageConfig;
+use Drupal\Tests\diff\Functional\CoreVersionUiTestTrait;
/**
* Tests the Diff module plugins.
/**
* Tests the Diff module plugins.
@@
-14,6
+15,7
@@
use Drupal\field\Entity\FieldStorageConfig;
class DiffPluginTest extends DiffPluginTestBase {
use CommentTestTrait;
class DiffPluginTest extends DiffPluginTestBase {
use CommentTestTrait;
+ use CoreVersionUiTestTrait;
/**
* Modules to enable.
/**
* Modules to enable.
@@
-78,10
+80,11
@@
class DiffPluginTest extends DiffPluginTestBase {
// Update the article and add a new revision, the "changed" field should be
// updated which does not have plugins provided by diff.
// Update the article and add a new revision, the "changed" field should be
// updated which does not have plugins provided by diff.
- $edit =
array(
+ $edit =
[
'revision' => TRUE,
'revision' => TRUE,
- );
- $this->drupalPostForm('node/' . $node->id() . '/edit', $edit, t('Save and keep published'));
+ 'body[0][value]' => 'change',
+ ];
+ $this->drupalPostNodeForm('node/' . $node->id() . '/edit', $edit, t('Save and keep published'));
// Check the difference between the last two revisions.
$this->clickLink(t('Revisions'));
// Check the difference between the last two revisions.
$this->clickLink(t('Revisions'));
@@
-151,7
+154,7
@@
class DiffPluginTest extends DiffPluginTestBase {
'test_field_non_applicable[0][value]' => 'nicer_not_applicable',
'revision' => TRUE,
];
'test_field_non_applicable[0][value]' => 'nicer_not_applicable',
'revision' => TRUE,
];
- $this->drupalPostForm('node/' . $node->id() . '/edit', $edit, t('Save and keep published'));
+ $this->drupalPost
Node
Form('node/' . $node->id() . '/edit', $edit, t('Save and keep published'));
// Check differences between revisions.
$this->clickLink(t('Revisions'));
// Check differences between revisions.
$this->clickLink(t('Revisions'));
@@
-195,13
+198,10
@@
class DiffPluginTest extends DiffPluginTestBase {
'body[0][value]' => '<p>body</p>
',
];
'body[0][value]' => '<p>body</p>
',
];
- $this->drupalPostForm('node/' . $node->id() . '/edit', $edit, t('Save and keep published'));
-
- // Assert the revision summary.
- $this->drupalGet('node/' . $node->id() . '/revisions');
- $this->assertText('Changes on: Body');
+ $this->drupalPostNodeForm('node/' . $node->id() . '/edit', $edit, t('Save and keep published'));
// Assert the revision comparison.
// Assert the revision comparison.
+ $this->drupalGet('node/' . $node->id() . '/revisions');
$this->drupalPostForm(NULL, [], t('Compare selected revisions'));
$this->assertNoText('No visible changes.');
$rows = $this->xpath('//tbody/tr');
$this->drupalPostForm(NULL, [], t('Compare selected revisions'));
$this->assertNoText('No visible changes.');
$rows = $this->xpath('//tbody/tr');
@@
-217,7
+217,7
@@
class DiffPluginTest extends DiffPluginTestBase {
<p>body_new</p>
',
];
<p>body_new</p>
',
];
- $this->drupalPostForm('node/' . $node->id() . '/edit', $edit, t('Save and keep published'));
+ $this->drupalPost
Node
Form('node/' . $node->id() . '/edit', $edit, t('Save and keep published'));
$this->drupalGet('node/' . $node->id() . '/revisions');
$this->drupalPostForm(NULL, [], t('Compare selected revisions'));
$this->assertNoText('No visible changes.');
$this->drupalGet('node/' . $node->id() . '/revisions');
$this->drupalPostForm(NULL, [], t('Compare selected revisions'));
$this->assertNoText('No visible changes.');