spec/cg_rect_spec.rb in geomotion-0.10.0 vs spec/cg_rect_spec.rb in geomotion-0.12.1
- old
+ new
@@ -6,12 +6,19 @@
describe ".make" do
it "should work with options" do
CGRectEqualToRect(@rect, CGRectMake(10, 100, 50, 20)).should == true
end
- it "should work with nested options" do
+ it "should work with nested options (CGPoint, CGSize)" do
CGRectEqualToRect(
CGRect.make(origin: CGPointMake(10, 100), size: CGSizeMake(50,20)),
+ CGRectMake(10, 100, 50, 20)
+ ).should == true
+ end
+
+ it "should work with nested options (Arrays)" do
+ CGRectEqualToRect(
+ CGRect.make(origin: [10, 100], size: [50,20]),
CGRectMake(10, 100, 50, 20)
).should == true
end
it "should work with no options" do