Skip to content

Commit

Permalink
Correct bw_geshi__example and its tests. Issue #15
Browse files Browse the repository at this point in the history
  • Loading branch information
bobbingwide committed May 15, 2021
1 parent cfe0c04 commit 89b54cb
Show file tree
Hide file tree
Showing 3 changed files with 22 additions and 6 deletions.
4 changes: 2 additions & 2 deletions shortcodes/oik-geshi.php
Original file line number Diff line number Diff line change
Expand Up @@ -127,11 +127,11 @@ function bw_geshi__syntax( $shortcode="bw_geshi" ) {
*
* @param string $shortcode
*/
function bw_geshi__example( $shortcode="bw_css" ) {
function bw_geshi__example( $shortcode="bw_geshi" ) {
$text = __( "Demonstrating the HTML to create a link to oik-plugins.com", "oik-css" );
BW_::p( $text );
$example = "[$shortcode";
$example .= ' html .]<a href="https://www.oik-plugins.com">' . __( "Visit oik-plugins.com", "oik-css" ) . '</a>[/bw_geshi';
$example .= ' lang=html]<a href="https://www.oik-plugins.com">' . __( "Visit oik-plugins.com", "oik-css" ) . '</a>[/bw_geshi';
$example .= ']';
sp();
stag( "code" );
Expand Down
12 changes: 10 additions & 2 deletions tests/data/bb_BB/test_bw_geshi__example_bb_BB.html
Original file line number Diff line number Diff line change
Expand Up @@ -3,9 +3,17 @@
</p>
<p>Dmenotsaritng thE HMTL tO certae A lnik tO OIk-puligns.cOm</p>
<p>
<code>[bw_css html .]&lt;a href=&quot;https://www.oik-plugins.com&quot;&gt;Vsiit OIk-puligns.cOm&lt;/a&gt;[/bw_geshi]</code>
<code>[bw_geshi lang=html]&lt;a href=&quot;https://www.oik-plugins.com&quot;&gt;Vsiit OIk-puligns.cOm&lt;/a&gt;[/bw_geshi]</code>
</p>
<div class="bw_geshi html5">
<code>
<span style="color: #009900;">&lt;<span style="color: #000000; font-weight: bold;">a</span> <span style="color: #000066;">href</span>
<span style="color: #66cc66;">=</span>
<span style="color: #ff0000;">&quot;https://www.oik-plugins.com&quot;</span>&gt;</span>Vsiit OIk-puligns.cOm<span style="color: #009900;">&lt;<span style="color: #66cc66;">/</span>
<span style="color: #000000; font-weight: bold;">a</span>&gt;</span>
</code>
</div>
<p>
<!--dotext:-->
<a href="https://www.oik-plugins.com">Vsiit OIk-puligns.cOm</a>[/bw_geshi]</p>
</p>

12 changes: 10 additions & 2 deletions tests/data/en_GB/test_bw_geshi__example.html
Original file line number Diff line number Diff line change
Expand Up @@ -3,9 +3,17 @@
</p>
<p>Demonstrating the HTML to create a link to oik-plugins.com</p>
<p>
<code>[bw_css html .]&lt;a href=&quot;https://www.oik-plugins.com&quot;&gt;Visit oik-plugins.com&lt;/a&gt;[/bw_geshi]</code>
<code>[bw_geshi lang=html]&lt;a href=&quot;https://www.oik-plugins.com&quot;&gt;Visit oik-plugins.com&lt;/a&gt;[/bw_geshi]</code>
</p>
<div class="bw_geshi html5">
<code>
<span style="color: #009900;">&lt;<span style="color: #000000; font-weight: bold;">a</span> <span style="color: #000066;">href</span>
<span style="color: #66cc66;">=</span>
<span style="color: #ff0000;">&quot;https://www.oik-plugins.com&quot;</span>&gt;</span>Visit oik-plugins.com<span style="color: #009900;">&lt;<span style="color: #66cc66;">/</span>
<span style="color: #000000; font-weight: bold;">a</span>&gt;</span>
</code>
</div>
<p>
<!--dotext:-->
<a href="https://www.oik-plugins.com">Visit oik-plugins.com</a>[/bw_geshi]</p>
</p>

0 comments on commit 89b54cb

Please sign in to comment.