TriangleSoup { public List<Triangle2D> getTriangles() { return this.triangleSoup; } TriangleSoup(); void add(Triangle2D triangle); void remove(Triangle2D triangle); List<Triangle2D> getTriangles(); Triangle2D findContainingTriangle(Vector2D point); Triangle2D findNeighbour(Triangle2D triangle, Edge2D edge); Triangle2D findOneTriangleSharing(Edge2D edge); Edge2D findNearestEdge(Vector2D point); void removeTrianglesUsing(Vector2D vertex);  }
@Test public void testThatTriangleSoupIsInitiallyEmpty() { TriangleSoup soup = new TriangleSoup(); List<Triangle2D> triangles = soup.getTriangles(); Assert.assertNotNull("The returned list should not be null.", triangles); Assert.assertEquals("The triangle soup should not contain any triangles if no triangles were added.", 0, triangles.size()); }