aboutsummaryrefslogtreecommitdiff
path: root/MindBox.Tests/FlatShapeAreaTests.cs
diff options
context:
space:
mode:
authorSerghei Cebotari <serghei@cebotari.ru>2023-11-13 22:40:23 +0300
committerSerghei Cebotari <serghei@cebotari.ru>2023-11-13 22:40:23 +0300
commit61a4fe90b89cc127444405597a2590f8537474e5 (patch)
tree44bfa66169cba2a7f2b79d959bf762b5e9bdeaa2 /MindBox.Tests/FlatShapeAreaTests.cs
Initial commit
Diffstat (limited to 'MindBox.Tests/FlatShapeAreaTests.cs')
-rw-r--r--MindBox.Tests/FlatShapeAreaTests.cs11
1 files changed, 11 insertions, 0 deletions
diff --git a/MindBox.Tests/FlatShapeAreaTests.cs b/MindBox.Tests/FlatShapeAreaTests.cs
new file mode 100644
index 0000000..9c4b5ca
--- /dev/null
+++ b/MindBox.Tests/FlatShapeAreaTests.cs
@@ -0,0 +1,11 @@
+namespace MindBox.Tests;
+
+public class FlatShapeAreaTests
+{
+ [TestCaseSource(typeof(CircleAreaCases))]
+ [TestCaseSource(typeof(TriangleAreaCases))]
+ public void AreaTest(FlatShape shape, double area)
+ {
+ Assert.That(shape.GetArea(), Is.EqualTo(area).Within(1e-6));
+ }
+}