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

Stationary_Detector when an allocation fails: buffering the hash of a frame throws std::bad_alloc, which reaches the caller of the callback, and leaves the hashes and their steps as they were. More...

#include <gtest/gtest.h>
#include "allocation_failure.H"
#include <cstddef>
#include <limits>
#include <new>
#include <string>
#include <utility>
#include <ca-observer.H>
#include <tpl_array.H>
#include <tpl_ca_lattice.H>
#include <tpl_ca_storage.H>
Include dependency graph for ca_observer_allocation_test.cc:

Go to the source code of this file.

Functions

 TEST (StationaryDetectorAllocation, AFailedBufferingReachesTheCaller)
 
 TEST (StationaryDetectorAllocation, AFullSmallWindowKeepsEachHashWithItsStep)
 
 TEST (StationaryDetectorAllocation, AFrameLostToAFailureMakesNoLongerCycle)
 

Detailed Description

Stationary_Detector when an allocation fails: buffering the hash of a frame throws std::bad_alloc, which reaches the caller of the callback, and leaves the hashes and their steps as they were.

This program replaces the global operator new, so that a test can make an allocation fail.

Definition in file ca_observer_allocation_test.cc.

Function Documentation

◆ TEST() [1/3]

◆ TEST() [2/3]

◆ TEST() [3/3]