From e2fb9c34d6f56ec833e0451b26a02c304afaf71b Mon Sep 17 00:00:00 2001 From: Tom Black Date: Wed, 26 Sep 2018 17:21:34 -0700 Subject: Documentation and style updates --- test/rectangle_spec.rb | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) (limited to 'test/rectangle_spec.rb') diff --git a/test/rectangle_spec.rb b/test/rectangle_spec.rb index 940b6cc..bbf1616 100644 --- a/test/rectangle_spec.rb +++ b/test/rectangle_spec.rb @@ -1,13 +1,14 @@ require 'ruby2d' RSpec.describe Ruby2D::Rectangle do - describe '#contains?' do - it "returns true if point is inside rectangle" do + + describe "#contains?" do + it "returns true if point is inside the rectangle" do rectangle = Rectangle.new(x: 0, y: 0, width: 50, height: 50) expect(rectangle.contains?(25, 25)).to be true end - it "returns true if point is not inside rectangle" do + it "returns true if point is outside the rectangle" do rectangle = Rectangle.new(x: 0, y: 0, width: 50, height: 50) expect(rectangle.contains?(-25, 25)).to be false expect(rectangle.contains?( 25, -25)).to be false @@ -15,4 +16,5 @@ RSpec.describe Ruby2D::Rectangle do expect(rectangle.contains?( 50, 25)).to be false end end + end -- cgit v1.2.3