|
Aleph-w 7.10.0
A C++ Library for Data Structures and Algorithms
|
Tests of Bounded_Cycle_Index: the catalog against a search made apart, the numbers of the arcs, the weights, the filter and its margin, the changes of several arcs, the limits and the failures. More...
#include <gtest/gtest.h>#include <algorithm>#include <cmath>#include <cstdint>#include <functional>#include <limits>#include <map>#include <random>#include <set>#include <stdexcept>#include <type_traits>#include <utility>#include <vector>#include <gmpxx.h>#include <Bounded_Cycle_Index.H>#include <tpl_agraph.H>#include <tpl_const_graph_view.H>#include <tpl_graph.H>#include <tpl_sgraph.H>Go to the source code of this file.
Functions | |
| TYPED_TEST (BoundedCycleIndexOn, HasTheCatalogOfASearchMadeApart) | |
| TYPED_TEST (BoundedCycleIndexOn, DoesNotDependOnTheOrderOfInsertion) | |
| TEST (BoundedCycleIndex, CountsTheCyclesOfACompleteDigraph) | |
| TEST (BoundedCycleIndex, OrdersTheCatalogAndKeepsThePrefixes) | |
| TEST (BoundedCycleIndex, TellsParallelArcsLoopsAndSensesApart) | |
| TEST (BoundedCycleIndex, NumbersTheArcsInTheOrderGiven) | |
| TEST (BoundedCycleIndex, StartsWithArcsThatCannotBeUsed) | |
| TYPED_TEST (BoundedCycleIndexOn, UpdateHandsTheCyclesBelowTheBound) | |
| TEST (BoundedCycleIndex, HandsTheSameSumWhicheverArcChanged) | |
| TYPED_TEST (BoundedCycleIndexOn, HandsOnceEachCycleOfSeveralArcs) | |
| TEST (BoundedCycleIndex, WalksTheWholeCatalog) | |
| TEST (BoundedCycleIndex, GivesEmptyRanges) | |
| TEST (BoundedCycleIndex, RejectsWhatIsNotValid) | |
| TEST (BoundedCycleIndex, HasLimits) | |
| TEST (BoundedCycleIndex, HoldsMoreArcsThanFitIn16Bits) | |
| TEST (BoundedCycleIndex, StaysWholeWhenTheFunctionThrows) | |
| TEST (BoundedCycleIndex, StampsTheWritesOfEachArc) | |
| TEST (BoundedCycleIndex, SwapsAndCopies) | |
| TEST (BoundedCycleIndex, StartsACopyMadeInsideAQueryWithoutMarks) | |
| TEST (BoundedCycleIndex, LeavesAnIndexThatIsMovedFromWithoutArcsAndCycles) | |
| TEST (BoundedCycleIndex, KeepsWhatItHadWhenItIsAssignedToItself) | |
| TEST (BoundedCycleIndex, ClearsTheMarkOfAnArcWhenTheFunctionThrowsAfterIt) | |
| TEST (BoundedCycleIndex, NeedsTheBoundRoundedUp) | |
| TEST (BoundedCycleIndex, HasOnlyTheLoopsWhenOnlyTheyAreAskedFor) | |
| TEST (BoundedCycleIndex, BoundsTheErrorOfTheSum) | |
Tests of Bounded_Cycle_Index: the catalog against a search made apart, the numbers of the arcs, the weights, the filter and its margin, the changes of several arcs, the limits and the failures.
Definition in file bounded_cycle_index_test.cc.
| TEST | ( | BoundedCycleIndex | , |
| BoundsTheErrorOfTheSum | |||
| ) |
Definition at line 1253 of file bounded_cycle_index_test.cc.
References abs(), Aleph::error(), __gmp_expr< mpq_t, mpq_t >::get_d(), k, rng, Aleph::sum(), and w.
| TEST | ( | BoundedCycleIndex | , |
| ClearsTheMarkOfAnArcWhenTheFunctionThrowsAfterIt | |||
| ) |
| TEST | ( | BoundedCycleIndex | , |
| CountsTheCyclesOfACompleteDigraph | |||
| ) |
Definition at line 440 of file bounded_cycle_index_test.cc.
References k, Aleph::Bounded_Cycle_Index< GT >::num_cycles(), and Aleph::Bounded_Cycle_Index< GT >::num_cycles_up_to().
| TEST | ( | BoundedCycleIndex | , |
| GivesEmptyRanges | |||
| ) |
Definition at line 759 of file bounded_cycle_index_test.cc.
References Aleph::count().
| TEST | ( | BoundedCycleIndex | , |
| HandsTheSameSumWhicheverArcChanged | |||
| ) |
Definition at line 632 of file bounded_cycle_index_test.cc.
References Aleph::sum().
| TEST | ( | BoundedCycleIndex | , |
| HasLimits | |||
| ) |
Definition at line 857 of file bounded_cycle_index_test.cc.
References Aleph::List_Graph< _Graph_Node, _Graph_Arc >::insert_node().
| TEST | ( | BoundedCycleIndex | , |
| HasOnlyTheLoopsWhenOnlyTheyAreAskedFor | |||
| ) |
Definition at line 1227 of file bounded_cycle_index_test.cc.
References Aleph::Bounded_Cycle_Index< GT >::arc(), Aleph::Bounded_Cycle_Index< GT >::cycle_arcs(), Aleph::Bounded_Cycle_Index< GT >::cycles_of(), and Aleph::Bounded_Cycle_Index< GT >::num_cycles().
| TEST | ( | BoundedCycleIndex | , |
| HoldsMoreArcsThanFitIn16Bits | |||
| ) |
Definition at line 881 of file bounded_cycle_index_test.cc.
References chain(), Aleph::Bounded_Cycle_Index< GT >::cycles_of(), Aleph::Bounded_Cycle_Index< GT >::for_each_cycle_below(), Aleph::Bounded_Cycle_Index< GT >::num_arcs(), Aleph::Bounded_Cycle_Index< GT >::num_cycles(), rng, Aleph::Bounded_Cycle_Index< GT >::set_weight(), Aleph::sum(), Aleph::Bounded_Cycle_Index< GT >::update(), and w.
| TEST | ( | BoundedCycleIndex | , |
| KeepsWhatItHadWhenItIsAssignedToItself | |||
| ) |
Definition at line 1155 of file bounded_cycle_index_test.cc.
References Aleph::Bounded_Cycle_Index< GT >::num_arcs(), Aleph::Bounded_Cycle_Index< GT >::set_weight(), and Aleph::Bounded_Cycle_Index< GT >::swap().
| TEST | ( | BoundedCycleIndex | , |
| LeavesAnIndexThatIsMovedFromWithoutArcsAndCycles | |||
| ) |
Definition at line 1111 of file bounded_cycle_index_test.cc.
References Aleph::copy(), Aleph::Bounded_Cycle_Index< GT >::set_weight(), and Aleph::Bounded_Cycle_Index< GT >::swap().
| TEST | ( | BoundedCycleIndex | , |
| NeedsTheBoundRoundedUp | |||
| ) |
Definition at line 1202 of file bounded_cycle_index_test.cc.
References Aleph::count(), and Aleph::Bounded_Cycle_Index< GT >::sum_error_bound().
| TEST | ( | BoundedCycleIndex | , |
| NumbersTheArcsInTheOrderGiven | |||
| ) |
Definition at line 527 of file bounded_cycle_index_test.cc.
References Aleph::Bounded_Cycle_Index< GT >::arc(), Aleph::Bounded_Cycle_Index< GT >::arc_number(), and Aleph::Bounded_Cycle_Index< GT >::num_arcs().
| TEST | ( | BoundedCycleIndex | , |
| OrdersTheCatalogAndKeepsThePrefixes | |||
| ) |
Definition at line 465 of file bounded_cycle_index_test.cc.
References Aleph::and, Aleph::Array< T >::append(), arcs, Aleph::Bounded_Cycle_Index< GT >::cycle_arcs(), Aleph::Bounded_Cycle_Index< GT >::has_length(), k, m, Aleph::Bounded_Cycle_Index< GT >::num_cycles(), Aleph::Bounded_Cycle_Index< GT >::num_cycles_up_to(), Aleph::prefix(), and rng.
| TEST | ( | BoundedCycleIndex | , |
| RejectsWhatIsNotValid | |||
| ) |
Definition at line 819 of file bounded_cycle_index_test.cc.
References Aleph::count().
| TEST | ( | BoundedCycleIndex | , |
| StampsTheWritesOfEachArc | |||
| ) |
Definition at line 965 of file bounded_cycle_index_test.cc.
| TEST | ( | BoundedCycleIndex | , |
| StartsACopyMadeInsideAQueryWithoutMarks | |||
| ) |
Definition at line 1072 of file bounded_cycle_index_test.cc.
References Aleph::each().
| TEST | ( | BoundedCycleIndex | , |
| StartsWithArcsThatCannotBeUsed | |||
| ) |
Definition at line 554 of file bounded_cycle_index_test.cc.
References Aleph::count(), Aleph::Bounded_Cycle_Index< GT >::cycles_of(), Aleph::Bounded_Cycle_Index< GT >::for_each_cycle_below(), Aleph::Bounded_Cycle_Index< GT >::num_arcs(), Aleph::Bounded_Cycle_Index< GT >::num_cycles(), Aleph::Bounded_Cycle_Index< GT >::set_weight(), Aleph::Bounded_Cycle_Index< GT >::update(), Aleph::Bounded_Cycle_Index< GT >::weight(), and Aleph::Bounded_Cycle_Index< GT >::weight_sum().
| TEST | ( | BoundedCycleIndex | , |
| StaysWholeWhenTheFunctionThrows | |||
| ) |
Definition at line 927 of file bounded_cycle_index_test.cc.
References Aleph::count(), Aleph::Bounded_Cycle_Index< GT >::cycles_of(), Aleph::Bounded_Cycle_Index< GT >::for_each_cycle_below(), Aleph::Bounded_Cycle_Index< GT >::num_arcs(), Aleph::Bounded_Cycle_Index< GT >::set_weight(), Aleph::Bounded_Cycle_Index< GT >::update(), and Aleph::Bounded_Cycle_Index< GT >::weight().
| TEST | ( | BoundedCycleIndex | , |
| SwapsAndCopies | |||
| ) |
Definition at line 1001 of file bounded_cycle_index_test.cc.
References Aleph::Bounded_Cycle_Index< GT >::clock(), Aleph::copy(), Aleph::Bounded_Cycle_Index< GT >::cycles_of(), Aleph::Bounded_Cycle_Index< GT >::for_each_cycle_below(), Aleph::Bounded_Cycle_Index< GT >::longest_length(), Aleph::Bounded_Cycle_Index< GT >::num_arcs(), Aleph::Bounded_Cycle_Index< GT >::num_cycles(), Aleph::Bounded_Cycle_Index< GT >::set_weight(), Aleph::Bounded_Cycle_Index< GT >::stamp(), Aleph::Bounded_Cycle_Index< GT >::update(), Aleph::Bounded_Cycle_Index< GT >::weight(), and Aleph::Bounded_Cycle_Index< GT >::weight_sum().
| TEST | ( | BoundedCycleIndex | , |
| TellsParallelArcsLoopsAndSensesApart | |||
| ) |
Definition at line 505 of file bounded_cycle_index_test.cc.
References Aleph::Cycle.
| TEST | ( | BoundedCycleIndex | , |
| WalksTheWholeCatalog | |||
| ) |
| TYPED_TEST | ( | BoundedCycleIndexOn | , |
| DoesNotDependOnTheOrderOfInsertion | |||
| ) |
Definition at line 419 of file bounded_cycle_index_test.cc.
References Aleph::Bounded_Cycle_Index< GT >::arc(), Aleph::Bounded_Cycle_Index< GT >::cycle_arcs(), Aleph::Bounded_Cycle_Index< GT >::num_arcs(), Aleph::Bounded_Cycle_Index< GT >::num_cycles(), and rng.
| TYPED_TEST | ( | BoundedCycleIndexOn | , |
| HandsOnceEachCycleOfSeveralArcs | |||
| ) |
Definition at line 654 of file bounded_cycle_index_test.cc.
References Aleph::Array< T >::append(), arcs, Aleph::Bounded_Cycle_Index< GT >::cycles_of(), Aleph::Bounded_Cycle_Index< GT >::for_each_cycle_below(), Aleph::Bounded_Cycle_Index< GT >::length(), m, Aleph::Bounded_Cycle_Index< GT >::num_arcs(), rng, Aleph::Bounded_Cycle_Index< GT >::set_weight(), Aleph::sum(), and Aleph::Bounded_Cycle_Index< GT >::weight_sum().
| TYPED_TEST | ( | BoundedCycleIndexOn | , |
| HasTheCatalogOfASearchMadeApart | |||
| ) |
Definition at line 358 of file bounded_cycle_index_test.cc.
References Aleph::Bounded_Cycle_Index< GT >::cycle_arcs(), GTArcCommon< ArcInfo >::get_info(), Aleph::Bounded_Cycle_Index< GT >::num_cycles(), and rng.
| TYPED_TEST | ( | BoundedCycleIndexOn | , |
| UpdateHandsTheCyclesBelowTheBound | |||
| ) |
Definition at line 583 of file bounded_cycle_index_test.cc.
References arcs, Aleph::Bounded_Cycle_Index< GT >::cycle_arcs(), Aleph::Bounded_Cycle_Index< GT >::cycles_of(), Aleph::Bounded_Cycle_Index< GT >::length(), Aleph::Bounded_Cycle_Index< GT >::num_arcs(), rng, Aleph::Bounded_Cycle_Index< GT >::set_weight(), Aleph::sum(), Aleph::Bounded_Cycle_Index< GT >::update(), w, and Aleph::Bounded_Cycle_Index< GT >::weight().