Modified test for wrap(String), added test for toggle(fn, fn)
[jquery.git] / src / jquery / jquery.js
index feb71e4..3edc303 100644 (file)
@@ -575,11 +575,16 @@ jQuery.fn = jQuery.prototype = {
         * @example $("p").wrap("<div class='wrap'></div>");
         * @before <p>Test Paragraph.</p>
         * @result <div class='wrap'><p>Test Paragraph.</p></div>
+        * 
+        * @test var defaultText = 'Try them out:'
+        * var result = $('#first').wrap('<div class="red"><span></span></div>').text();
+        * ok( defaultText == result, 'Check for simple wrapping' );
+        * ok( $('#first').parent().parent().is('.red'), 'Check if wrapper div has class "red"' );
         *
         * @test var defaultText = 'Try them out:'
-        * @test var result = $('#first').wrap('<div class="red">xx<span></span>yy</div>').text()
+        * var result = $('#first').wrap('<div class="red">xx<span></span>yy</div>').text()
         * ok( 'xx' + defaultText + 'yy' == result, 'Check for wrapping' );
-        * @test ok( $('#first').parent().parent().is('.red'), 'Check if wrapper div has class "red"' );
+        * ok( $('#first').parent().parent().is('.red'), 'Check if wrapper div has class "red"' );
         *
         * @name wrap
         * @type jQuery
@@ -1977,7 +1982,8 @@ jQuery.extend({
         * @example $.map( [0,1,2], function(i){
         *   return [ i, i + 1 ];
         * });
-        * @result [0, 1, 1, 2, 2, 3]\r   *
+        * @result [0, 1, 1, 2, 2, 3]
+        *
         * @name $.map
         * @type Array
         * @param Array array The Array to translate.