summaryrefslogtreecommitdiffhomepage
path: root/test/rectangle_spec.rb
diff options
context:
space:
mode:
Diffstat (limited to 'test/rectangle_spec.rb')
-rw-r--r--test/rectangle_spec.rb20
1 files changed, 0 insertions, 20 deletions
diff --git a/test/rectangle_spec.rb b/test/rectangle_spec.rb
deleted file mode 100644
index bbf1616..0000000
--- a/test/rectangle_spec.rb
+++ /dev/null
@@ -1,20 +0,0 @@
-require 'ruby2d'
-
-RSpec.describe Ruby2D::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 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
- expect(rectangle.contains?( 25, 50)).to be false
- expect(rectangle.contains?( 50, 25)).to be false
- end
- end
-
-end