Sha256: 16e77905b54c1494d8a53a30edf4885eec14130bf4dd298ed8a794589f1763e3
Contents?: true
Size: 865 Bytes
Versions: 2
Compression:
Stored size: 865 Bytes
Contents
describe CCNode do describe "Children" do before do @node = CCNode.new end it "should have empty children subclasses" do @node.children.should == nil end it "should add subclass as a child" do sprite = Sprite.new file_name: 'sprite.png' @node << sprite @node.children.count.should == 1 end it "should add many subclasses as childs" do sprite = Sprite.new file_name: 'sprite.png' layer = Layer.new @node.add_children(sprite, layer) @node.children.count.should == 2 end it "should clean all the children subclasses" do @node.removeAllChildren @node.children.should == nil end it "should clean all the children subclasses and stop the actions" do @node.removeAllChildrenWithCleanup(true) @node.children.should == nil end end end
Version data entries
2 entries across 2 versions & 1 rubygems
Version | Path |
---|---|
joybox-1.1.1 | spec/motion/joybox/core/node_spec.rb |
joybox-1.1.0 | spec/motion/joybox/core/node_spec.rb |