Ignore:
Timestamp:
06/24/09 21:13:57 (3 years ago)
Author:
MichaelTempest
Message:

Item1770: Update documentation; add more unit tests

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/WysiwygPlugin/test/unit/WysiwygPlugin/ExtendedTranslatorTests.pm

    r4294 r4295  
    117117            Foswiki::Plugins::WysiwygPlugin::addXMLTag( 'customtag', 
    118118                sub { 1 } ); 
     119        }, 
     120        html => '<p>' 
     121          . $protecton 
     122          . '&lt;customtag&gt;some&nbsp;&gt;&nbsp;&nbsp;text&lt;/customtag&gt;' 
     123          . $protectoff . '</p>', 
     124        tml => '<customtag>some >  text</customtag>', 
     125    }, 
     126    { 
     127        exec  => $TML2HTML | $ROUNDTRIP, 
     128        name  => 'CustomXmlTagCallbackChangesText', 
     129        setup => sub { 
     130            Foswiki::Plugins::WysiwygPlugin::addXMLTag( 'customtag', 
     131                sub { $_[0] =~ s/some/different/; return 1; } ); 
     132        }, 
     133        html => '<p>' 
     134          . $protecton 
     135          . '&lt;customtag&gt;different&nbsp;&gt;&nbsp;&nbsp;text&lt;/customtag&gt;' 
     136          . $protectoff . '</p>', 
     137        tml      => '<customtag>some >  text</customtag>', 
     138        finaltml => '<customtag>different >  text</customtag>', 
     139    }, 
     140    { 
     141        exec  => $TML2HTML | $ROUNDTRIP, 
     142        name  => 'CustomXmlTagDefaultCallback', 
     143        setup => sub { 
     144            Foswiki::Plugins::WysiwygPlugin::addXMLTag( 'customtag' ); 
    119145        }, 
    120146        html => '<p>' 
Note: See TracChangeset for help on using the changeset viewer.