- div = jQuery("<div/>").data({ a: true, b: true });
- div = div.clone(true);
- equals( div.data("a"), true, "Data cloned." );
- equals( div.data("b"), true, "Data cloned." );
+ div = jQuery("<div/>").data({
+ a: true, b: true,
+ c: { nesty: ["Block", "Head"] }
+ });
+ var div2 = div.clone(true);
+ equals( div2.data("a"), true, "Data cloned." );
+ equals( div2.data("b"), true, "Data cloned." );
+ var c = div2.data("c");
+ c.nesty[0] = "Fish";
+ equals( div.data("c").nesty[0], "Block", "Ensure cloned element data is deep copied (Bug #7717)" );