Sha256: 8abdbb663881499394f81764882ecd29803f0e931d7e95cc58b3d1570ba0ce77

Contents?: true

Size: 523 Bytes

Versions: 42

Compression:

Stored size: 523 Bytes

Contents

describe "layout parent methods" do
  before do
    @subject = TestParentLayout.new.view.subviews.first
  end

  it "should be a UIView" do
    @subject.should.be.kind_of UIView
  end

  it "should set the first subview frame properly" do
    @subject.frame.should == CGRectMake(0, 0, 100, 60)
  end

  it "should use parent to set its frame properly" do
    @subject.subviews.first.frame.should == CGRectMake(10, 10, 50, 30)
    @subject.subviews.first.subviews.first.frame.should == CGRectMake(25, 15, 40, 20)
  end

end

Version data entries

42 entries across 36 versions & 1 rubygems

Version Path
motion-kit-1.1.1 spec/tvos/parent_layout_spec.rb
motion-kit-1.1.1 spec/ios/parent_layout_spec.rb
motion-kit-1.1.0 spec/tvos/parent_layout_spec.rb
motion-kit-1.1.0 spec/ios/parent_layout_spec.rb
motion-kit-1.0.3 spec/tvos/parent_layout_spec.rb
motion-kit-1.0.3 spec/ios/parent_layout_spec.rb
motion-kit-1.0.2 spec/ios/parent_layout_spec.rb
motion-kit-1.0.2 spec/tvos/parent_layout_spec.rb
motion-kit-1.0.1 spec/ios/parent_layout_spec.rb
motion-kit-1.0.1 spec/tvos/parent_layout_spec.rb
motion-kit-1.0.0 spec/tvos/parent_layout_spec.rb
motion-kit-1.0.0 spec/ios/parent_layout_spec.rb
motion-kit-0.18.0 spec/ios/parent_layout_spec.rb
motion-kit-0.17.0 spec/ios/parent_layout_spec.rb
motion-kit-0.16.0 spec/ios/parent_layout_spec.rb
motion-kit-0.15.0 spec/ios/parent_layout_spec.rb
motion-kit-0.14.2 spec/ios/parent_layout_spec.rb
motion-kit-0.14.1 spec/ios/parent_layout_spec.rb
motion-kit-0.14.0 spec/ios/parent_layout_spec.rb
motion-kit-0.13.0 spec/ios/parent_layout_spec.rb