// Copyright 2012 Citrix Systems, Inc. Licensed under the // Apache License, Version 2.0 (the "License"); you may not use this // file except in compliance with the License. Citrix Systems, Inc. // reserves all rights not expressly granted by the License. // You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 // Unless required by applicable law or agreed to in writing, software // distributed under the License is distributed on an "AS IS" BASIS, // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. // See the License for the specific language governing permissions and // limitations under the License. // // Automatically generated by addcopyright.py at 04/03/2012 (function($) { module('Detail view', { setup: function() { cloudStack.dialog.__confirm = cloudStack.dialog.confirm; cloudStack.ui.notifications.__add = cloudStack.ui.notifications.add; $.fn.__cloudBrowser = $.fn.cloudBrowser; $.fn.__listView = $.fn.listView; $.fn.__dataTable = $.fn.dataTable; $.fn.__is = $.fn.is; $.fn.is = function(args) { if (args == ':visible') return true; // No test elems will ever be shown, so just pretend they are visible return true; }; }, teardown: function() { cloudStack.dialog.confirm = cloudStack.dialog.__confirm; cloudStack.ui.notifications.add = cloudStack.ui.notifications.__add; $.fn.cloudBrowser = $.fn.__cloudBrowser; $.fn.listView = $.fn.__listView; $.fn.dataTable = $.fn.__dataTable; $.fn.is = $.fn.__is; } }); test('Basic', function() { var detailView = { tabs: { tabA: { title: 'tabA', fields: [{}], dataProvider: function() {} }, tabB: { title: 'tabB', fields: [{}], dataProvider: function() {} } } }; var $detailView = $('