#include <boost/test/unit_test.hpp>
#include "Graph.hpp"
#include "Observable.hpp"
Go to the source code of this file.
◆ BOOST_AUTO_TEST_CASE() [1/4]
BOOST_AUTO_TEST_CASE |
( |
AddedLayerObservableTest |
| ) |
|
Definition at line 13 of file ObservableTest.cpp.
References Graph::AddLayer(), GraphObservable< ObservedType >::begin(), GraphObservable< ObservedType >::end(), and Graph::InsertNewLayer().
25 std::list<armnn::Layer*> testLayers({ output, input });
27 BOOST_CHECK_EQUAL_COLLECTIONS(layerObservable.begin(), layerObservable.end(),
28 testLayers.begin(), testLayers.end());
LayerT * AddLayer(Args &&... args)
Adds a new layer, of type LayerType, to the graph constructed with the arguments passed.
A layer user-provided data can be bound to (e.g. inputs, outputs).
LayerT * InsertNewLayer(InputSlot &insertBefore, Args &&... args)
Inserts a new layer between the output slot currently connected to insertBefore and insertBefore itse...
◆ BOOST_AUTO_TEST_CASE() [2/4]
BOOST_AUTO_TEST_CASE |
( |
ClearAddedLayerObservableTest |
| ) |
|
Definition at line 31 of file ObservableTest.cpp.
References Graph::AddLayer(), GraphObservable< ObservedType >::begin(), GraphObservable< ObservedType >::Clear(), GraphObservable< ObservedType >::end(), and Graph::InsertNewLayer().
42 addedLayerObservable.Clear();
45 std::list<armnn::Layer*> emptyList({});
47 BOOST_CHECK_EQUAL_COLLECTIONS(addedLayerObservable.begin(), addedLayerObservable.end(),
48 emptyList.begin(), emptyList.end());
LayerT * AddLayer(Args &&... args)
Adds a new layer, of type LayerType, to the graph constructed with the arguments passed.
A layer user-provided data can be bound to (e.g. inputs, outputs).
LayerT * InsertNewLayer(InputSlot &insertBefore, Args &&... args)
Inserts a new layer between the output slot currently connected to insertBefore and insertBefore itse...
◆ BOOST_AUTO_TEST_CASE() [3/4]
BOOST_AUTO_TEST_CASE |
( |
ErasedLayerNamesObservableTest |
| ) |
|
Definition at line 51 of file ObservableTest.cpp.
References Graph::AddLayer(), GraphObservable< ObservedType >::begin(), GraphObservable< ObservedType >::end(), Graph::EraseLayer(), and Graph::InsertNewLayer().
65 std::list<std::string> testList({
"output"});
67 BOOST_CHECK_EQUAL_COLLECTIONS(erasedLayerNamesObservable.begin(), erasedLayerNamesObservable.end(),
68 testList.begin(), testList.end());
LayerT * AddLayer(Args &&... args)
Adds a new layer, of type LayerType, to the graph constructed with the arguments passed.
void EraseLayer(Iterator pos)
Deletes the layer at the specified position.
A layer user-provided data can be bound to (e.g. inputs, outputs).
LayerT * InsertNewLayer(InputSlot &insertBefore, Args &&... args)
Inserts a new layer between the output slot currently connected to insertBefore and insertBefore itse...
◆ BOOST_AUTO_TEST_CASE() [4/4]
BOOST_AUTO_TEST_CASE |
( |
ClearErasedLayerNamesObservableTest |
| ) |
|
Definition at line 71 of file ObservableTest.cpp.
References Graph::AddLayer(), GraphObservable< ObservedType >::begin(), BOOST_AUTO_TEST_SUITE_END(), GraphObservable< ObservedType >::Clear(), GraphObservable< ObservedType >::end(), Graph::EraseLayer(), and Graph::InsertNewLayer().
84 erasedLayerNamesObservable.Clear();
87 std::list<std::string> emptyList({});
89 BOOST_CHECK_EQUAL_COLLECTIONS(erasedLayerNamesObservable.begin(), erasedLayerNamesObservable.end(),
90 emptyList.begin(), emptyList.end());
LayerT * AddLayer(Args &&... args)
Adds a new layer, of type LayerType, to the graph constructed with the arguments passed.
void EraseLayer(Iterator pos)
Deletes the layer at the specified position.
A layer user-provided data can be bound to (e.g. inputs, outputs).
LayerT * InsertNewLayer(InputSlot &insertBefore, Args &&... args)
Inserts a new layer between the output slot currently connected to insertBefore and insertBefore itse...