KiCad PCB EDA Suite
|
#include <boost/test/unit_test.hpp>
#include "color4d_test_utils.h"
#include <qa_utils/wx_utils/unit_test_utils.h>
#include <gal/color4d.h>
#include <wx/colour.h>
Go to the source code of this file.
Classes | |
struct | COLOR_SCALAR_CASE |
Test case data for a test that takes a colour and a scalar factor and returns a result. More... | |
struct | FROM_HSV_TO_HEX_CASE |
struct | FROM_HSL_TO_HEX_CASE |
struct | WX_CONV_CASE |
Functions | |
BOOST_AUTO_TEST_CASE (BasicOps) | |
Declares a struct as the Boost test fixture. | |
BOOST_AUTO_TEST_CASE (Invert) | |
Check inversion. | |
BOOST_AUTO_TEST_CASE (Brighten) | |
Check inversion. | |
BOOST_AUTO_TEST_CASE (Darken) | |
Check darken. | |
BOOST_AUTO_TEST_CASE (WithAlpha) | |
Check alpha setting. | |
BOOST_AUTO_TEST_CASE (FromHsv) | |
Check FromHSV. | |
BOOST_AUTO_TEST_CASE (FromHsl) | |
Check FromHSL. | |
BOOST_AUTO_TEST_CASE (ToWx) | |
Check conversion to WxColour. | |
BOOST_AUTO_TEST_CASE (FromWx) | |
Check conversion from WxColour. | |
BOOST_AUTO_TEST_CASE (Compare) | |
Check the Compare method and hashing. | |
Variables | |
static std::vector< WX_CONV_CASE > | wx_conv_cases |
BOOST_AUTO_TEST_CASE | ( | BasicOps | ) |
Declares a struct as the Boost test fixture.
Check basic setting and getting of values
Definition at line 47 of file test_color4d.cpp.
BOOST_AUTO_TEST_CASE | ( | Brighten | ) |
Check inversion.
Definition at line 107 of file test_color4d.cpp.
BOOST_AUTO_TEST_CASE | ( | Compare | ) |
Check the Compare method and hashing.
Definition at line 312 of file test_color4d.cpp.
References KIGFX::COLOR4D::a, KIGFX::COLOR4D::b, KIGFX::COLOR4D::Compare(), KIGFX::COLOR4D::g, and KIGFX::COLOR4D::r.
BOOST_AUTO_TEST_CASE | ( | Darken | ) |
Check darken.
Definition at line 131 of file test_color4d.cpp.
BOOST_AUTO_TEST_CASE | ( | FromHsl | ) |
Check FromHSL.
Definition at line 231 of file test_color4d.cpp.
References KIGFX::COLOR4D::FromHSL(), and KI_TEST::IsColorNearHex().
BOOST_AUTO_TEST_CASE | ( | FromHsv | ) |
Check FromHSV.
Definition at line 189 of file test_color4d.cpp.
References KIGFX::COLOR4D::FromHSV(), and KI_TEST::IsColorNearHex().
BOOST_AUTO_TEST_CASE | ( | FromWx | ) |
Check conversion from WxColour.
Definition at line 296 of file test_color4d.cpp.
References KI_TEST::IsColorNear(), and wx_conv_cases.
BOOST_AUTO_TEST_CASE | ( | Invert | ) |
Check inversion.
Definition at line 83 of file test_color4d.cpp.
BOOST_AUTO_TEST_CASE | ( | ToWx | ) |
Check conversion to WxColour.
Definition at line 278 of file test_color4d.cpp.
References wx_conv_cases.
BOOST_AUTO_TEST_CASE | ( | WithAlpha | ) |
Check alpha setting.
Definition at line 155 of file test_color4d.cpp.
|
static |
Definition at line 267 of file test_color4d.cpp.
Referenced by BOOST_AUTO_TEST_CASE().