/*
* widget unit tests
*/
-(function($) {
+(function( $ ) {
-module('widget: tickets');
+module( "widget: tickets" );
-test('#5830 - Widget: Using inheritance overwrites the base classes options', function() {
+test( "#5830 - Widget: Using inheritance overwrites the base classes options", function() {
$.widget( "ui.testWidgetBase", {
options: {
obj: {
arr: [ "testing" ]
}
});
-
+
$.widget( "ui.testWidgetExtension", $.ui.testWidgetBase, {
options: {
obj: {
arr: [ "alpha", "beta" ]
}
});
-
+
same( $.ui.testWidgetBase.prototype.options.obj, {
key1: "foo",
key2: "bar"
}, "extension class option object extends base");
same( $.ui.testWidgetExtension.prototype.options.arr, [ "alpha", "beta" ],
"extension class option array overwrites base");
-
+
delete $.ui.testWidgetBase;
delete $.ui.testWidgetExtension;
});
-})(jQuery);
+})( jQuery );