Aleph-w 3.0
A C++ Library for Data Structures and Algorithms
Loading...
Searching...
No Matches
tpl_ca_storage_test.cc File Reference

Unit tests for Phase 1 cell storages (Dense_Cell_Storage, Bit_Cell_Storage). More...

#include <cstdint>
#include <limits>
#include <stdexcept>
#include <type_traits>
#include <utility>
#include <gtest/gtest.h>
#include <tpl_ca_concepts.H>
#include <tpl_ca_storage.H>
#include <tpl_ca_bit_storage.H>
Include dependency graph for tpl_ca_storage_test.cc:

Go to the source code of this file.

Functions

 TEST (CADenseCellStorage, DefaultConstructedIsEmpty)
 
 TEST (CADenseCellStorage, ConstructorAllocatesAndInitialises)
 
 TEST (CADenseCellStorage, RowMajorLinearIndex)
 
 TEST (CADenseCellStorage, SetAndAtRoundTrip2D)
 
 TEST (CADenseCellStorage, SetAndAt3D)
 
 TEST (CADenseCellStorage, OneDimensional)
 
 TEST (CADenseCellStorage, OutOfRangeThrows)
 
 TEST (CADenseCellStorage, FillResetsAllCells)
 
 TEST (CADenseCellStorage, SwapIsConstantTimeAndExchanges)
 
 TEST (CADenseCellStorage, FreeFunctionSwap)
 
 TEST (CADenseCellStorage, ViewMatchesShapeAndAliasesTheSameBuffer)
 
 TEST (CADenseCellStorage, EmptyStorageViewReturnsEmptyView)
 
 TEST (CADenseCellStorage, WriteThroughViewIsVisibleThroughStorageApi)
 
 TEST (CADenseCellStorage, WriteThroughStorageIsVisibleThroughView)
 
 TEST (CADenseCellStorage, ConstStorageYieldsReadOnlyView)
 
 TEST (CADenseCellStorage, ViewRowMajorOrderMatchesLinearIndex)
 
 TEST (CADenseCellStorage, ViewOverThreeDimensionalStorage)
 
 TEST (CADenseCellStorage, MoveTransfersOwnership)
 
 TEST (CABitCellStorage, DefaultConstructedIsEmpty)
 
 TEST (CABitCellStorage, ConstructorInitialisesValue)
 
 TEST (CABitCellStorage, SetAndAtRoundTrip)
 
 TEST (CABitCellStorage, RowMajorLinearIndex)
 
 TEST (CABitCellStorage, FillToggles)
 
 TEST (CABitCellStorage, SwapExchangesContentsAndExtents)
 
 TEST (CABitCellStorage, OutOfRangeThrows)
 
 TEST (CABitCellStorage, ThreeDimensional)
 
 TEST (CABitCellStorage, ExtentsProductOverflowThrows)
 

Detailed Description

Unit tests for Phase 1 cell storages (Dense_Cell_Storage, Bit_Cell_Storage).

Verifies shape, indexing, copy/move semantics, swap and fill, plus a pair of static_assert checks confirming both storages still satisfy the Phase 0 LatticeLike concept.

Definition in file tpl_ca_storage_test.cc.

Function Documentation

◆ TEST() [1/27]

TEST ( CABitCellStorage  ,
ConstructorInitialisesValue   
)

◆ TEST() [2/27]

TEST ( CABitCellStorage  ,
DefaultConstructedIsEmpty   
)

◆ TEST() [3/27]

TEST ( CABitCellStorage  ,
ExtentsProductOverflowThrows   
)

Definition at line 337 of file tpl_ca_storage_test.cc.

References Aleph::blossom_maximum_cardinality_matching(), and max().

◆ TEST() [4/27]

TEST ( CABitCellStorage  ,
FillToggles   
)

◆ TEST() [5/27]

TEST ( CABitCellStorage  ,
OutOfRangeThrows   
)

◆ TEST() [6/27]

TEST ( CABitCellStorage  ,
RowMajorLinearIndex   
)

◆ TEST() [7/27]

TEST ( CABitCellStorage  ,
SetAndAtRoundTrip   
)

◆ TEST() [8/27]

TEST ( CABitCellStorage  ,
SwapExchangesContentsAndExtents   
)

◆ TEST() [9/27]

TEST ( CABitCellStorage  ,
ThreeDimensional   
)

◆ TEST() [10/27]

TEST ( CADenseCellStorage  ,
ConstructorAllocatesAndInitialises   
)

◆ TEST() [11/27]

TEST ( CADenseCellStorage  ,
ConstStorageYieldsReadOnlyView   
)

◆ TEST() [12/27]

◆ TEST() [13/27]

TEST ( CADenseCellStorage  ,
EmptyStorageViewReturnsEmptyView   
)

◆ TEST() [14/27]

TEST ( CADenseCellStorage  ,
FillResetsAllCells   
)

◆ TEST() [15/27]

TEST ( CADenseCellStorage  ,
FreeFunctionSwap   
)

◆ TEST() [16/27]

◆ TEST() [17/27]

TEST ( CADenseCellStorage  ,
OneDimensional   
)

◆ TEST() [18/27]

TEST ( CADenseCellStorage  ,
OutOfRangeThrows   
)

◆ TEST() [19/27]

TEST ( CADenseCellStorage  ,
RowMajorLinearIndex   
)

◆ TEST() [20/27]

TEST ( CADenseCellStorage  ,
SetAndAt3D   
)

◆ TEST() [21/27]

TEST ( CADenseCellStorage  ,
SetAndAtRoundTrip2D   
)

◆ TEST() [22/27]

TEST ( CADenseCellStorage  ,
SwapIsConstantTimeAndExchanges   
)

◆ TEST() [23/27]

◆ TEST() [24/27]

TEST ( CADenseCellStorage  ,
ViewOverThreeDimensionalStorage   
)

◆ TEST() [25/27]

TEST ( CADenseCellStorage  ,
ViewRowMajorOrderMatchesLinearIndex   
)

◆ TEST() [26/27]

TEST ( CADenseCellStorage  ,
WriteThroughStorageIsVisibleThroughView   
)

◆ TEST() [27/27]

TEST ( CADenseCellStorage  ,
WriteThroughViewIsVisibleThroughStorageApi   
)