Skip to content

Commit d0ef762

Browse files
committed
Add failing test for the "old" quote format
1 parent 1236c5d commit d0ef762

File tree

1 file changed

+35
-0
lines changed

1 file changed

+35
-0
lines changed

tests/WordPress/GutenbergTest.php

Lines changed: 35 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -169,6 +169,13 @@ public function it_transforms_quotes_blocks()
169169
<p>Exercitation nostrud minim proident minim minim aliqua tempor incididunt laboris in. Id non reprehenderit sint excepteur cillum.</p>
170170
<!-- /wp:paragraph --><cite>John Doe</cite></blockquote>
171171
<!-- /wp:quote -->
172+
173+
<!-- wp:quote {"align":"left"} -->
174+
<blockquote class="wp-block-quote has-text-align-left">
175+
<p>“Ea eiusmod ad non magna et tempor non qui magna. Id labore veniam Lorem do elit do veniam magna et aliquip voluptate consectetur nulla aliquip.”</p>
176+
<cite>John Doe</cite>
177+
</blockquote>
178+
<!-- /wp:quote -->
172179
HTML
173180
);
174181

@@ -216,6 +223,34 @@ public function it_transforms_quotes_blocks()
216223
],
217224
],
218225
],
226+
[
227+
'type' => 'blockquote',
228+
'content' => [
229+
[
230+
'type' => 'paragraph',
231+
'attrs' => ['textAlign' => 'left'],
232+
'content' => [
233+
[
234+
'type' => 'text',
235+
'text' => '“Ea eiusmod ad non magna et tempor non qui magna. Id labore veniam Lorem do elit do veniam magna et aliquip voluptate consectetur nulla aliquip.”',
236+
],
237+
],
238+
],
239+
[
240+
'type' => 'paragraph',
241+
'attrs' => ['textAlign' => 'left'],
242+
'content' => [
243+
[
244+
'type' => 'hardBreak',
245+
],
246+
[
247+
'type' => 'text',
248+
'text' => 'John Doe',
249+
],
250+
],
251+
],
252+
],
253+
],
219254
], $output);
220255
}
221256

0 commit comments

Comments
 (0)