diff options
author | jzaefferer <joern.zaefferer@gmail.com> | 2010-04-03 17:08:45 +0200 |
---|---|---|
committer | jzaefferer <joern.zaefferer@gmail.com> | 2010-04-03 17:08:45 +0200 |
commit | ad5bfc7f604bf298ecfeac77db50081fc33dbfd0 (patch) | |
tree | 98510a0c627a70d2b30eec21ff923ff064bd15c9 /tests/unit/accordion/accordion.html | |
parent | 87ba795467ee447eb2ab7d95ada42de097c7946f (diff) | |
download | jquery-ui-ad5bfc7f604bf298ecfeac77db50081fc33dbfd0.tar.gz jquery-ui-ad5bfc7f604bf298ecfeac77db50081fc33dbfd0.zip |
Accordion unit tests: Refactored state-helper function
Diffstat (limited to 'tests/unit/accordion/accordion.html')
-rw-r--r-- | tests/unit/accordion/accordion.html | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/tests/unit/accordion/accordion.html b/tests/unit/accordion/accordion.html index df0979803..9b6cb63f2 100644 --- a/tests/unit/accordion/accordion.html +++ b/tests/unit/accordion/accordion.html @@ -16,6 +16,18 @@ <script type="text/javascript" src="../../jquery.simulate.js"></script> <script type="text/javascript" src="../testsuite.js"></script> + <script type="text/javascript"> + $.ui.accordion.prototype.options.animated = false; + + function state(accordion) { + var args = $.makeArray(arguments).slice(1); + var result = []; + $.each(args, function(i, n) { + result.push( accordion.find(".ui-accordion-content").eq(i).is(":visible") ? 1 : 0 ); + }); + same(args, result) + } + </script> <script type="text/javascript" src="accordion_core.js"></script> <script type="text/javascript" src="accordion_defaults.js"></script> <script type="text/javascript" src="accordion_events.js"></script> |