+++ /dev/null
-/*
- * Unit Test: Gallery3d
- *
- * Wonseop Kim <wonseop.kim@samsung.com>
- */
-
-(function ($) {
- $.mobile.defaultTransition = "none";
-
- module("Galley3d");
-
- asyncTest( "create & select", function() {
- var widget = $( "#galley3dTest1" ),
- imageList = [],
- path = widget.attr( "data-json-url" ),
- key = widget.attr( "data-json-key" ),
- elem = "ui-gallery3d";
-
- $.ajax({
- async : false,
- url : path,
- dataType: "json",
- success : function ( result ) {
- imageList = result[key];
- }
- });
-
- /* Create */
- widget.gallery3d();
- ok( widget.hasClass( elem ), "Create" );
-
- /* API */
- widget.gallery3d( "select", 1 );
- setTimeout( function () {
- equal( widget.gallery3d( "select" ), imageList[1].src, "API : select" );
- start();
- }, 2400 );
- });
-
- asyncTest( "remove", function() {
- var widget = $( "#galley3dTest2" ),
- imageList = [],
- path = widget.attr( "data-json-url" ),
- key = widget.attr( "data-json-key" ),
- currentSource;
-
- $.ajax({
- async : false,
- url : path,
- dataType: "json",
- success : function ( result ) {
- imageList = result[key];
- }
- });
-
- widget.gallery3d();
- currentSource = widget.gallery3d( "select" );
-
- /* API */
- widget.gallery3d( "remove" );
- notEqual( widget.gallery3d( "select" ), currentSource, "API : remove" );
- start();
- });
-
- asyncTest( "move", function() {
- var widget = $( "#galley3dTest3" ),
- imageList = [],
- path = widget.attr( "data-json-url" ),
- key = widget.attr( "data-json-key" ),
- currentSource;
-
- $.ajax({
- async : false,
- url : path,
- dataType: "json",
- success : function ( result ) {
- imageList = result[key];
- }
- });
-
- widget.gallery3d();
- currentSource = widget.gallery3d( "select" );
-
- /* API */
- widget.gallery3d( "moveNext" );
- setTimeout( function () {
- equal( widget.gallery3d( "select" ), imageList[1].src, "API : moveNext" );
- start();
-
- stop();
- widget.gallery3d( "movePrev" );
- setTimeout( function () {
- equal( widget.gallery3d( "select" ), imageList[0].src, "API : movePrev" );
- start();
- }, 300 );
- }, 2400 );
- });
-
-}( jQuery ));
+++ /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.js"></script>
- <script src="../../../build/tizen-web-ui-fw/latest/js/tizen-web-ui-fw.js"
- data-framework-theme="tizen-gray"
- 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="gallery3d-tests.js"></script>
-
- <title>Galley3d</title>
-</head>
-
-<body>
-
-<h1 id="qunit-header">Galley3d</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">
- <div data-role="header" data-position="fixed">
- <h1>Galley3d</h1>
- </div>
- <div data-role="content">
- <div id="galley3dTest1" data-role="galley3d" style="width: 100%;"
- data-json-url="../../../demos/tizen-gray/widgets/gallery3d/gallery3d-db.json"
- data-json-key="JSON_DATA" > </div>
- </div>
- </div>
-
- <div data-role="page">
- <div data-role="header" data-position="fixed">
- <h1>Galley3d</h1>
- </div>
- <div data-role="content">
- <div id="galley3dTest2" data-role="galley3d" style="width: 100%;"
- data-json-url="../../../demos/tizen-gray/widgets/gallery3d/gallery3d-db.json"
- data-json-key="JSON_DATA" > </div>
- </div>
- </div>
-
- <div data-role="page">
- <div data-role="header" data-position="fixed">
- <h1>Galley3d</h1>
- </div>
- <div data-role="content">
- <div id="galley3dTest3" data-role="galley3d" style="width: 100%;"
- data-json-url="../../../demos/tizen-gray/widgets/gallery3d/gallery3d-db.json"
- data-json-key="JSON_DATA" > </div>
- </div>
- </div>
-
-</div>
-
-</body>
-</html>