array.html revision eb86457f85638a9eb7c4d5f84eb367d24061abfb
<html>
<head>
<title>YUI Array Tests</title>
</head>
<body class="yui-skin-sam">
<h1>Array Tests</h1>
<p><input type="button" value="Run Tests" id="btnRun" disabled="true" /></p>
<script type="text/javascript">
(function() {
YUI({
base: "/build/",
filter: "debug",
useConsole: true
}).use("dump", "test", "console", "event-custom", function(Y) {
var button = Y.get('#btnRun');
// Set up the page
button.set("disabled", false);
Y.on("click", function() {
}, button);
var myConsole = new Y.Console().render();
var testObject = new Y.Test.Case({
name: "Array tests",
testNumericSort: function() {
Y.ArrayAssert.itemsAreEqual([1, 2, 3], [3, 1, 2].sort(Y.Array.numericSort));
}
});
Y.Test.Runner.add(testObject);
});
})();
</script>
</body>
</html>