Commit 79463501 authored by Alan D.'s avatar Alan D. Committed by olstjos

Issue #2870965 by Alan D.: New / Alternative Media Filter P Fix filter option

parent 33cb44b7
......@@ -35,7 +35,6 @@ class MediaWYSIWYGParagraphFixFilterTest extends MediaWYSIWYGTestHelper {
$edit = array(
'filters[media_filter][status]' => TRUE,
'filters[filter_autop][status]' => FALSE,
'filters[filter_url][status]' => FALSE,
'filters[filter_html][status]' => FALSE,
'filters[filter_htmlcorrector][status]' => FALSE,
);
......@@ -61,12 +60,10 @@ class MediaWYSIWYGParagraphFixFilterTest extends MediaWYSIWYGTestHelper {
// Enable the default P fix filter.
$edit = array(
'filters[media_filter_paragraph_fix][status]' => TRUE,
'filters[media_filter_paragraph_fix][settings][replace]' => FALSE,
);
$this->drupalPost('admin/config/content/formats/filtered_html', $edit, t('Save configuration'));
// Retest the content to check nested paragraphs are removed.
$nid = $this->createNode($file->fid);
$this->drupalGet('node/' . $nid);
$this->assertNoPattern($this->default_regexp, t('Nested media DIV tags within paragraphs with filter defaults.'));
$this->assertNoPattern($this->replace_regexp, t('No replacement DIV tag found with filter defaults.'));
......@@ -78,7 +75,6 @@ class MediaWYSIWYGParagraphFixFilterTest extends MediaWYSIWYGTestHelper {
$this->drupalPost('admin/config/content/formats/filtered_html', $edit, t('Save configuration'));
// Test that the replace text was found.
$nid = $this->createNode($file->fid);
$this->drupalGet('node/' . $nid);
$this->assertNoPattern($this->default_regexp, t('No nested media DIV tags within paragraphs with filter P replacement.'));
$this->assertPattern($this->replace_regexp, t('No replacement DIV tag found with filter P replacement.'));
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment