--- /dev/null
+<!DOCTYPE html>
+<html>
+<head>
+ <script src="../../../build/tizen-web-ui-fw/latest/js/jquery.js"></script>
+ <script src="../../../build/tizen-web-ui-fw/latest/js/tizen-web-ui-fw-libs.min.js"></script>
+ <script src="../../../build/tizen-web-ui-fw/latest/js/tizen-web-ui-fw.js"
+ data-framework-theme="tizen-white"
+ data-framework-viewport-scale=false>
+ </script>
+
+ <link rel="stylesheet" href="../../../libs/js/jquery-mobile-1.2.0/external/qunit.css" />
+
+ <script src="../../../libs/js/jquery-mobile-1.2.0/external/qunit.js"></script>
+ <script src="progress-tests.js"></script>
+
+ <title>Progress</title>
+</head>
+
+<body>
+
+<h1 id="qunit-header">Progressbar</h1>
+<h2 id="qunit-banner"></h2>
+<div id="qunit-testrunner-toolbar"></div>
+<h2 id="qunit-userAgent"></h2>
+<ol id="qunit-tests"></ol>
+
+<div id="qunit-fixture">
+
+ <div data-role="page" id="progress_demo">
+ <div data-role="header" data-position="fixed">
+ <h1>Progressbar</h1>
+ </div>
+ <div data-role="content">
+ <ul data-role="listview">
+ <li><div data-role="progressing" data-style="pending" id="pending"></div></li>
+ <li><div data-role="progressing" data-style="circle" id="progressing"></div></li>
+ </ul>
+ </div>
+ </div>
+
+</div>
+
+</body>
+</html>
--- /dev/null
+/*
+ * Unit Test: Progress
+ *
+ * Minkyu Kang <mk7.kang@samsung.com>
+ */
+
+(function ($) {
+ module("Progress");
+
+ var unit_progress = function ( widget, type ) {
+ var progress,
+ elem = ".ui-progress-" + type,
+ _class = "ui-progress-" + type + "-running";
+
+ widget.progress();
+
+ /* Create */
+ progress = widget.find( elem );
+ ok( progress, "Create" );
+
+ /* Option */
+ equal( widget.progress( "option", "style" ), type, "Option: style" );
+
+ /* Running */
+ widget.progress( "running", true );
+ progress = widget.find( elem );
+ equal( progress.hasClass( _class ), true, "API: running" );
+
+ /* Stop */
+ widget.progress( "running", false );
+ progress = widget.find( elem );
+ equal( progress.hasClass( _class ), false, "API: stop" );
+ };
+
+ test( "pending bar", function () {
+ unit_progress( $("#pending"), "pending" );
+ });
+
+ test( "processing circle", function () {
+ unit_progress( $("#progressing"), "circle" );
+ });
+}( jQuery ));
<div data-role="content">
<ul data-role="listview">
<li><div data-role="progressbar" id="progressbar"></div></li>
- <li><div data-role="progressing" data-style="pending" id="pending"></div></li>
- <li><div data-role="progressing" data-style="circle" id="progressing"></div></li>
</ul>
</div>
</div>
}
};
- var unit_progress = function ( widget, type ) {
- var progress,
- elem = ".ui-progress-" + type,
- _class = "ui-progress-" + type + "-running";
-
- widget.progress();
-
- /* Create */
- progress = widget.find( elem );
- ok( progress, "Create" );
-
- /* Option */
- equal( widget.progress( "option", "style" ), type, "Option: style" );
-
- /* Running */
- widget.progress( "running", true );
- progress = widget.find( elem );
- equal( progress.hasClass( _class ), true, "API: running" );
-
- /* Stop */
- widget.progress( "running", false );
- progress = widget.find( elem );
- equal( progress.hasClass( _class ), false, "API: stop" );
- };
-
test( "progressbar", function () {
unit_progressbar( $("#progressbar") );
});
-
- test( "pending bar", function () {
- unit_progress( $("#pending"), "pending" );
- });
-
- test( "processing circle", function () {
- unit_progress( $("#progressing"), "circle" );
- });
}( jQuery ));
"popupwindow",
"popupwindow_ctxpopup",
"progressbar",
+ "progress",
"radio",
"searchbar",
"segmentcontrol",