KiCad PCB EDA Suite
Loading...
Searching...
No Matches
test_oval.cpp File Reference
#include <boost/test/unit_test.hpp>
#include <geometry/oval.h>
#include "geom_test_utils.h"

Go to the source code of this file.

Classes

struct  OvalFixture
 
struct  OVAL_POINTS_TEST_CASE
 

Functions

template<typename T >
void CHECK_COLLECTIONS_SAME_UNORDERED (const T &expected, const T &actual)
 Check that two collections contain the same elements, ignoring order.
 
void DoOvalPointTestChecks (const OVAL_POINTS_TEST_CASE &testcase)
 
 BOOST_AUTO_TEST_CASE (SimpleOvalVertical)
 
 BOOST_AUTO_TEST_CASE (SimpleOvalHorizontal)
 
 BOOST_AUTO_TEST_CASE (SimpleOval45Degrees)
 

Function Documentation

◆ BOOST_AUTO_TEST_CASE() [1/3]

BOOST_AUTO_TEST_CASE ( SimpleOval45Degrees  )

Definition at line 138 of file test_oval.cpp.

References DEGREES_T, and DoOvalPointTestChecks().

◆ BOOST_AUTO_TEST_CASE() [2/3]

BOOST_AUTO_TEST_CASE ( SimpleOvalHorizontal  )

Definition at line 111 of file test_oval.cpp.

References DEGREES_T, and DoOvalPointTestChecks().

◆ BOOST_AUTO_TEST_CASE() [3/3]

BOOST_AUTO_TEST_CASE ( SimpleOvalVertical  )

Definition at line 84 of file test_oval.cpp.

References DEGREES_T, and DoOvalPointTestChecks().

◆ CHECK_COLLECTIONS_SAME_UNORDERED()

template<typename T >
void CHECK_COLLECTIONS_SAME_UNORDERED ( const T &  expected,
const T &  actual 
)

Check that two collections contain the same elements, ignoring order.

I.e. expected contains everything in actual and vice versa.

The collections lengths are also checked to weed out unexpected duplicates.

Parameters
expecteda collection of expected elements
actuala collection of actual elements

Definition at line 41 of file test_oval.cpp.

References expected.

Referenced by DoOvalPointTestChecks().

◆ DoOvalPointTestChecks()