KiCad PCB EDA Suite
Loading...
Searching...
No Matches
test_drawing_sheet_reactive.cpp File Reference
#include <boost/test/unit_test.hpp>
#include <algorithm>
#include <base_units.h>
#include <drawing_sheet/ds_data_item.h>
#include <drawing_sheet/ds_data_model.h>
#include <drawing_sheet/ds_draw_item.h>
#include <drawing_sheet/ds_proxy_view_item.h>
#include <page_info.h>
#include <text_var_dependency.h>
#include <title_block.h>

Go to the source code of this file.

Macros

#define BOOST_TEST_NO_MAIN
 

Functions

 BOOST_AUTO_TEST_CASE (CollectKeysFindsTitleBlockSources)
 
 BOOST_AUTO_TEST_CASE (AttachRegistersProxyAsDependent)
 
 BOOST_AUTO_TEST_CASE (InvalidationReachesProxyViaListener)
 
 BOOST_AUTO_TEST_CASE (DetachUnregistersProxy)
 
 BOOST_AUTO_TEST_CASE (DestructorAutoUnregisters)
 
 BOOST_AUTO_TEST_CASE (RepeatedTextKeepsAllInstancesWithNegativeStep)
 
static int repeatCountAtY (double aY)
 
 BOOST_AUTO_TEST_CASE (RepeatedTextAnchoredInPageMarginKeepsItsRepeats)
 
static std::vector< wxString > repeatTexts (const wxString &aBase, int aCount, int aLabelStep)
 
 BOOST_AUTO_TEST_CASE (RepeatedLabelStepsLettersAndNumbersCleanly)
 
 BOOST_CHECK_EQUAL_COLLECTIONS (mixed.begin(), mixed.end(), expMixed.begin(), expMixed.end())
 
 BOOST_CHECK_EQUAL_COLLECTIONS (fullWidth.begin(), fullWidth.end(), expFullWidth.begin(), expFullWidth.end())
 

Variables

const std::vector< wxString > expMixed
 
const std::vector< wxString > fullWidth = repeatTexts( wxString( L"1" ), 3, 1 )
 
const std::vector< wxString > expFullWidth
 

Macro Definition Documentation

◆ BOOST_TEST_NO_MAIN

#define BOOST_TEST_NO_MAIN

Definition at line 20 of file test_drawing_sheet_reactive.cpp.

Function Documentation

◆ BOOST_AUTO_TEST_CASE() [1/8]

◆ BOOST_AUTO_TEST_CASE() [2/8]

BOOST_AUTO_TEST_CASE ( CollectKeysFindsTitleBlockSources )

◆ BOOST_AUTO_TEST_CASE() [3/8]

◆ BOOST_AUTO_TEST_CASE() [4/8]

◆ BOOST_AUTO_TEST_CASE() [5/8]

◆ BOOST_AUTO_TEST_CASE() [6/8]

BOOST_AUTO_TEST_CASE ( RepeatedLabelStepsLettersAndNumbersCleanly )

◆ BOOST_AUTO_TEST_CASE() [7/8]

BOOST_AUTO_TEST_CASE ( RepeatedTextAnchoredInPageMarginKeepsItsRepeats )

Definition at line 233 of file test_drawing_sheet_reactive.cpp.

References BOOST_CHECK_EQUAL(), and repeatCountAtY().

◆ BOOST_AUTO_TEST_CASE() [8/8]

◆ BOOST_CHECK_EQUAL_COLLECTIONS() [1/2]

BOOST_CHECK_EQUAL_COLLECTIONS ( fullWidth. begin(),
fullWidth. end(),
expFullWidth. begin(),
expFullWidth. end() )

References expFullWidth, and fullWidth.

◆ BOOST_CHECK_EQUAL_COLLECTIONS() [2/2]

BOOST_CHECK_EQUAL_COLLECTIONS ( mixed. begin(),
mixed. end(),
expMixed. begin(),
expMixed. end() )

References expMixed.

Referenced by BOOST_AUTO_TEST_CASE(), BOOST_AUTO_TEST_CASE(), BOOST_AUTO_TEST_CASE(), BOOST_AUTO_TEST_CASE(), BOOST_AUTO_TEST_CASE(), BOOST_AUTO_TEST_CASE(), BOOST_AUTO_TEST_CASE(), BOOST_AUTO_TEST_CASE(), BOOST_AUTO_TEST_CASE(), BOOST_AUTO_TEST_CASE(), BOOST_AUTO_TEST_CASE(), BOOST_AUTO_TEST_CASE(), BOOST_AUTO_TEST_CASE(), BOOST_AUTO_TEST_CASE(), BOOST_AUTO_TEST_CASE(), BOOST_AUTO_TEST_CASE(), BOOST_AUTO_TEST_CASE(), BOOST_AUTO_TEST_CASE(), BOOST_AUTO_TEST_CASE(), BOOST_AUTO_TEST_CASE(), BOOST_AUTO_TEST_CASE(), BOOST_AUTO_TEST_CASE(), BOOST_AUTO_TEST_CASE(), BOOST_AUTO_TEST_CASE(), BOOST_AUTO_TEST_CASE(), BOOST_AUTO_TEST_CASE(), BOOST_AUTO_TEST_CASE(), BOOST_AUTO_TEST_CASE(), BOOST_AUTO_TEST_CASE(), BOOST_AUTO_TEST_CASE(), BOOST_AUTO_TEST_CASE(), BOOST_AUTO_TEST_CASE(), BOOST_AUTO_TEST_CASE(), BOOST_AUTO_TEST_CASE(), BOOST_AUTO_TEST_CASE(), BOOST_AUTO_TEST_CASE(), BOOST_AUTO_TEST_CASE(), BOOST_AUTO_TEST_CASE(), BOOST_AUTO_TEST_CASE(), BOOST_AUTO_TEST_CASE(), BOOST_AUTO_TEST_CASE(), BOOST_AUTO_TEST_CASE(), BOOST_AUTO_TEST_CASE(), BOOST_AUTO_TEST_CASE(), BOOST_AUTO_TEST_CASE(), BOOST_AUTO_TEST_CASE(), BOOST_AUTO_TEST_CASE(), BOOST_AUTO_TEST_CASE(), BOOST_AUTO_TEST_CASE(), BOOST_AUTO_TEST_CASE(), BOOST_AUTO_TEST_CASE(), BOOST_AUTO_TEST_CASE(), BOOST_AUTO_TEST_CASE(), BOOST_AUTO_TEST_CASE(), BOOST_AUTO_TEST_CASE(), BOOST_AUTO_TEST_CASE(), BOOST_AUTO_TEST_CASE(), BOOST_AUTO_TEST_CASE(), BOOST_AUTO_TEST_CASE(), BOOST_AUTO_TEST_CASE(), BOOST_DATA_TEST_CASE(), BOOST_FIXTURE_TEST_CASE(), BOOST_FIXTURE_TEST_CASE(), CheckArrayNumbering(), and CheckPadNumberProvider().

◆ repeatCountAtY()

◆ repeatTexts()

static std::vector< wxString > repeatTexts ( const wxString & aBase,
int aCount,
int aLabelStep )
static

Variable Documentation

◆ expFullWidth

const std::vector<wxString> expFullWidth
Initial value:
= { wxString( L"1" ), wxString( L"1" ),
wxString( L"1" ) }

Definition at line 299 of file test_drawing_sheet_reactive.cpp.

Referenced by BOOST_CHECK_EQUAL_COLLECTIONS().

◆ expMixed

const std::vector<wxString> expMixed
Initial value:
= { wxString( L"1あ" ), wxString( L"2あ" ),
wxString( L"3あ" ) }

Definition at line 293 of file test_drawing_sheet_reactive.cpp.

Referenced by BOOST_CHECK_EQUAL_COLLECTIONS().

◆ fullWidth

const std::vector<wxString> fullWidth = repeatTexts( wxString( L"1" ), 3, 1 )

Definition at line 298 of file test_drawing_sheet_reactive.cpp.

Referenced by BOOST_CHECK_EQUAL_COLLECTIONS().