3-phase PV router
Loading...
Searching...
No Matches
test_main.cpp File Reference

Native unit tests for utils_override.h. More...

#include <unity.h>
#include "utils_override.h"
Include dependency graph for test_main.cpp:

Go to the source code of this file.

Functions

int main (void)
 
void setUp (void)
 
void tearDown (void)
 
void test_are_pins_valid_all_valid (void)
 
void test_are_pins_valid_rejects_pin_0 (void)
 
void test_are_pins_valid_rejects_pin_1 (void)
 
void test_are_pins_valid_rejects_pin_14_and_above (void)
 
void test_indicesToBitmask_all_bits (void)
 
void test_indicesToBitmask_consecutive (void)
 
void test_indicesToBitmask_multiple_indices (void)
 
void test_indicesToBitmask_single_index (void)
 
void test_KeyIndexPair_construction (void)
 
void test_KeyIndexPair_from_bitmask (void)
 
void test_KeyIndexPair_getBitmask (void)
 
void test_KeyIndexPair_single_pin (void)
 
void test_OverridePins_findBitmask_found (void)
 
void test_OverridePins_findBitmask_not_found (void)
 
void test_OverridePins_getBitmask_out_of_bounds (void)
 
void test_OverridePins_getPin_out_of_bounds (void)
 
void test_OverridePins_many_entries (void)
 
void test_OverridePins_multiple_entries (void)
 
void test_OverridePins_single_entry (void)
 
void test_OverridePins_with_bitmask_constructor (void)
 
void test_PinList_default_constructor (void)
 
void test_PinList_from_bitmask (void)
 
void test_PinList_from_bitmask_empty (void)
 
void test_PinList_from_bitmask_full (void)
 
void test_PinList_max_pins (void)
 
void test_PinList_single_pin (void)
 
void test_PinList_toBitmask (void)
 
void test_PinList_variadic_constructor (void)
 

Detailed Description

Native unit tests for utils_override.h.

Tests pure C++ bitmask utilities: PinList, KeyIndexPair, OverridePins, indicesToBitmask, are_pins_valid. No config.h, no stubs - just the real code.

Definition in file test_main.cpp.

Function Documentation

◆ main()

int main ( void )

Definition at line 276 of file test_main.cpp.

Here is the call graph for this function:

◆ setUp()

void setUp ( void )

Definition at line 13 of file test_main.cpp.

◆ tearDown()

void tearDown ( void )

Definition at line 14 of file test_main.cpp.

◆ test_are_pins_valid_all_valid()

void test_are_pins_valid_all_valid ( void )

Definition at line 49 of file test_main.cpp.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ test_are_pins_valid_rejects_pin_0()

void test_are_pins_valid_rejects_pin_0 ( void )

Definition at line 57 of file test_main.cpp.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ test_are_pins_valid_rejects_pin_1()

void test_are_pins_valid_rejects_pin_1 ( void )

Definition at line 63 of file test_main.cpp.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ test_are_pins_valid_rejects_pin_14_and_above()

void test_are_pins_valid_rejects_pin_14_and_above ( void )

Definition at line 69 of file test_main.cpp.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ test_indicesToBitmask_all_bits()

void test_indicesToBitmask_all_bits ( void )

Definition at line 39 of file test_main.cpp.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ test_indicesToBitmask_consecutive()

void test_indicesToBitmask_consecutive ( void )

Definition at line 33 of file test_main.cpp.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ test_indicesToBitmask_multiple_indices()

void test_indicesToBitmask_multiple_indices ( void )

Definition at line 27 of file test_main.cpp.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ test_indicesToBitmask_single_index()

void test_indicesToBitmask_single_index ( void )

Definition at line 20 of file test_main.cpp.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ test_KeyIndexPair_construction()

void test_KeyIndexPair_construction ( void )

Definition at line 146 of file test_main.cpp.

Here is the caller graph for this function:

◆ test_KeyIndexPair_from_bitmask()

void test_KeyIndexPair_from_bitmask ( void )

Definition at line 169 of file test_main.cpp.

Here is the caller graph for this function:

◆ test_KeyIndexPair_getBitmask()

void test_KeyIndexPair_getBitmask ( void )

Definition at line 154 of file test_main.cpp.

Here is the caller graph for this function:

◆ test_KeyIndexPair_single_pin()

void test_KeyIndexPair_single_pin ( void )

Definition at line 162 of file test_main.cpp.

Here is the caller graph for this function:

◆ test_OverridePins_findBitmask_found()

void test_OverridePins_findBitmask_found ( void )

Definition at line 225 of file test_main.cpp.

Here is the caller graph for this function:

◆ test_OverridePins_findBitmask_not_found()

void test_OverridePins_findBitmask_not_found ( void )

Definition at line 238 of file test_main.cpp.

Here is the caller graph for this function:

◆ test_OverridePins_getBitmask_out_of_bounds()

void test_OverridePins_getBitmask_out_of_bounds ( void )

Definition at line 215 of file test_main.cpp.

Here is the caller graph for this function:

◆ test_OverridePins_getPin_out_of_bounds()

void test_OverridePins_getPin_out_of_bounds ( void )

Definition at line 205 of file test_main.cpp.

Here is the caller graph for this function:

◆ test_OverridePins_many_entries()

void test_OverridePins_many_entries ( void )

Definition at line 259 of file test_main.cpp.

Here is the caller graph for this function:

◆ test_OverridePins_multiple_entries()

void test_OverridePins_multiple_entries ( void )

Definition at line 191 of file test_main.cpp.

Here is the caller graph for this function:

◆ test_OverridePins_single_entry()

void test_OverridePins_single_entry ( void )

Definition at line 180 of file test_main.cpp.

Here is the caller graph for this function:

◆ test_OverridePins_with_bitmask_constructor()

void test_OverridePins_with_bitmask_constructor ( void )

Definition at line 248 of file test_main.cpp.

Here is the caller graph for this function:

◆ test_PinList_default_constructor()

void test_PinList_default_constructor ( void )

Definition at line 80 of file test_main.cpp.

Here is the caller graph for this function:

◆ test_PinList_from_bitmask()

void test_PinList_from_bitmask ( void )

Definition at line 118 of file test_main.cpp.

Here is the caller graph for this function:

◆ test_PinList_from_bitmask_empty()

void test_PinList_from_bitmask_empty ( void )

Definition at line 128 of file test_main.cpp.

Here is the caller graph for this function:

◆ test_PinList_from_bitmask_full()

void test_PinList_from_bitmask_full ( void )

Definition at line 135 of file test_main.cpp.

Here is the caller graph for this function:

◆ test_PinList_max_pins()

void test_PinList_max_pins ( void )

Definition at line 104 of file test_main.cpp.

Here is the caller graph for this function:

◆ test_PinList_single_pin()

void test_PinList_single_pin ( void )

Definition at line 96 of file test_main.cpp.

Here is the caller graph for this function:

◆ test_PinList_toBitmask()

void test_PinList_toBitmask ( void )

Definition at line 111 of file test_main.cpp.

Here is the caller graph for this function:

◆ test_PinList_variadic_constructor()

void test_PinList_variadic_constructor ( void )

Definition at line 87 of file test_main.cpp.

Here is the caller graph for this function: