|
Aleph-w 7.10.0
A C++ Library for Data Structures and Algorithms
|
Tests for Dyndlist. More...
#include <gtest/gtest.h>#include <stdexcept>#include <type_traits>#include <utility>#include <tpl_dynDlist.H>#include <ah-unique.H>#include <ah-convert.H>Go to the source code of this file.
Classes | |
| struct | List_of_25_items |
| struct | List_of_10_items |
Macros | |
| #define | Declare_list_n_items(num) |
Functions | |
| TEST (DynDlist, Basic_operations) | |
| TEST (DynDlist, Simple_append_and_insert_of_list) | |
| TEST (DynDlistAlgorithms, InPlaceUnique) | |
| TEST_F (List_of_10_items, copy_and_assignment) | |
| TEST_F (List_of_25_items, Basic_operations) | |
| TEST_F (List_of_25_items, Iterator_operations) | |
| TEST_F (List_of_25_items, Split_and_concat) | |
| TEST_F (List_of_25_items, swap) | |
| TEST_F (List_of_25_items, reverse) | |
| TEST_F (List_of_25_items, rotate_left) | |
| TEST_F (List_of_25_items, rotate_right) | |
| TEST_F (List_of_25_items, append_and_insert_by_moving) | |
| TEST (DynDlist, traverse_on_empty_container) | |
| TEST_F (List_of_25_items, traverse) | |
| TEST (DynDlist, RemoveAndEraseByReference) | |
| TEST (DynDlist, OperatorIndexEnforcesBounds) | |
| TEST_F (List_of_10_items, ConstReverseReturnsIndependentCopy) | |
| TEST (DynDlist, IteratorInsertAndAppendOperations) | |
| TEST (DynDlist, IteratorListOperations) | |
| TEST (DynDlist, IteratorListOperationsRequireCurrent) | |
| TEST (DynDlist, SplitGivesTheSizesOfTheHalves) | |
| TEST (DynDlist, SplitRequiresEmptyDestination) | |
| TEST (DynDlist, StackAndQueueAliases) | |
| TEST (DynDlistFunctional, ToArrayHelperPreservesOrder) | |
| TEST (DynDlist, RemovingAnEndMovesTheItem) | |
| TEST (DynDlist, AMoveThatThrowsLeavesTheItemInTheList) | |
| TEST (DynDlist, ARemoveMovesTheItemOnce) | |
| TEST (DynDlist, EqualityOperator) | |
| TEST (DynDlist, AMoveOfTheListBuildsNoItem) | |
| TEST (DynDlist, AMoveOfTheListThatThrowsLeavesItAsItWas) | |
| TEST (DynDlist, AListOfItemsThatCannotBeMovedIsMoved) | |
Tests for Dyndlist.
Definition in file dyndlist.cc.
| #define Declare_list_n_items | ( | num | ) |
Definition at line 52 of file dyndlist.cc.
| TEST | ( | DynDlist | , |
| AListOfItemsThatCannotBeMovedIsMoved | |||
| ) |
Definition at line 885 of file dyndlist.cc.
References LocateFunctions< Container, Type >::get_it(), Aleph::Dlink::is_empty(), and Aleph::DynDlist< T >::size().
| TEST | ( | DynDlist | , |
| AMoveOfTheListBuildsNoItem | |||
| ) |
Definition at line 816 of file dyndlist.cc.
References Aleph::DynDlist< T >::append(), Aleph::DynDlist< T >::get_first(), LocateFunctions< Container, Type >::get_it(), Aleph::DynDlist< T >::get_last(), and Aleph::DynDlist< T >::size().
| TEST | ( | DynDlist | , |
| AMoveOfTheListThatThrowsLeavesItAsItWas | |||
| ) |
Definition at line 846 of file dyndlist.cc.
| TEST | ( | DynDlist | , |
| AMoveThatThrowsLeavesTheItemInTheList | |||
| ) |
Definition at line 713 of file dyndlist.cc.
References Aleph::DynDlist< T >::append(), Aleph::DynDlist< T >::get_first(), Aleph::DynDlist< T >::get_last(), Aleph::DynDlist< T >::remove_first_ne(), Aleph::DynDlist< T >::remove_last_ne(), and Aleph::DynDlist< T >::size().
| TEST | ( | DynDlist | , |
| ARemoveMovesTheItemOnce | |||
| ) |
Definition at line 735 of file dyndlist.cc.
References Aleph::DynDlist< T >::append(), Aleph::DynDlist< T >::remove_first_ne(), Aleph::DynDlist< T >::remove_last_ne(), and Aleph::DynDlist< T >::size().
| TEST | ( | DynDlist | , |
| Basic_operations | |||
| ) |
Definition at line 71 of file dyndlist.cc.
References Aleph::DynDlist< T >::append(), Aleph::DynDlist< T >::get_first(), Aleph::DynDlist< T >::get_last(), Aleph::DynDlist< T >::insert(), Aleph::Dlink::is_empty(), Aleph::Dlink::is_unitarian(), Aleph::Dlink::is_unitarian_or_empty(), Aleph::DynDlist< T >::remove_first(), Aleph::Dlink::rotate_left(), and Aleph::DynDlist< T >::size().
| TEST | ( | DynDlist | , |
| EqualityOperator | |||
| ) |
Definition at line 751 of file dyndlist.cc.
| TEST | ( | DynDlist | , |
| IteratorInsertAndAppendOperations | |||
| ) |
Definition at line 482 of file dyndlist.cc.
References LocateFunctions< Container, Type >::get_it().
| TEST | ( | DynDlist | , |
| IteratorListOperations | |||
| ) |
Definition at line 507 of file dyndlist.cc.
References LocateFunctions< Container, Type >::get_it(), and Aleph::Dlink::is_empty().
| TEST | ( | DynDlist | , |
| IteratorListOperationsRequireCurrent | |||
| ) |
Definition at line 533 of file dyndlist.cc.
References LocateFunctions< Container, Type >::get_it(), Aleph::Dlink::is_empty(), and Aleph::DynDlist< T >::size().
| TEST | ( | DynDlist | , |
| OperatorIndexEnforcesBounds | |||
| ) |
Definition at line 441 of file dyndlist.cc.
References Aleph::DynDlist< T >::append().
| TEST | ( | DynDlist | , |
| RemoveAndEraseByReference | |||
| ) |
| TEST | ( | DynDlist | , |
| RemovingAnEndMovesTheItem | |||
| ) |
Definition at line 696 of file dyndlist.cc.
References Aleph::DynDlist< T >::append(), Aleph::Dlink::is_empty(), Aleph::DynDlist< T >::remove_first(), Aleph::DynDlist< T >::remove_first_ne(), Aleph::DynDlist< T >::remove_last(), Aleph::DynDlist< T >::remove_last_ne(), and Aleph::DynDlist< T >::size().
| TEST | ( | DynDlist | , |
| Simple_append_and_insert_of_list | |||
| ) |
Definition at line 120 of file dyndlist.cc.
References Aleph::DynDlist< T >::append(), Aleph::DynDlist< T >::get_first(), Aleph::DynDlist< T >::get_last(), Aleph::DynDlist< T >::insert(), Aleph::Dlink::is_empty(), Aleph::Dlink::is_unitarian(), Aleph::Dlink::is_unitarian_or_empty(), and Aleph::DynDlist< T >::size().
| TEST | ( | DynDlist | , |
| SplitGivesTheSizesOfTheHalves | |||
| ) |
Definition at line 555 of file dyndlist.cc.
References Aleph::DynList< T >::append(), Aleph::DynDlist< T >::append(), LocateFunctions< Container, Type >::get_it(), Aleph::Dlink::is_empty(), Aleph::HTList::is_empty(), l, r, Aleph::DynList< T >::remove_first(), Aleph::DynList< T >::size(), Aleph::DynDlist< T >::size(), Aleph::DynDlist< T >::split(), and Aleph::DynDlist< T >::split_list_ne().
| TEST | ( | DynDlist | , |
| SplitRequiresEmptyDestination | |||
| ) |
Definition at line 594 of file dyndlist.cc.
References Aleph::DynDlist< T >::append(), and Aleph::DynDlist< T >::empty().
| TEST | ( | DynDlist | , |
| StackAndQueueAliases | |||
| ) |
Definition at line 608 of file dyndlist.cc.
References Aleph::DynDlist< T >::front(), Aleph::DynDlist< T >::get(), Aleph::Dlink::is_empty(), Aleph::DynDlist< T >::pop(), Aleph::DynDlist< T >::push(), Aleph::DynDlist< T >::put(), Aleph::DynDlist< T >::rear(), and Aleph::DynDlist< T >::top().
| TEST | ( | DynDlist | , |
| traverse_on_empty_container | |||
| ) |
Definition at line 401 of file dyndlist.cc.
References m, and GenericTraverse< Container >::traverse().
| TEST | ( | DynDlistAlgorithms | , |
| InPlaceUnique | |||
| ) |
Definition at line 164 of file dyndlist.cc.
References Aleph::DynDlist< T >::append(), LocateFunctions< Container, Type >::get_it(), Aleph::in_place_unique(), and Aleph::DynDlist< T >::size().
| TEST | ( | DynDlistFunctional | , |
| ToArrayHelperPreservesOrder | |||
| ) |
Definition at line 631 of file dyndlist.cc.
References Aleph::DynDlist< T >::append(), LocateFunctions< Container, Type >::get_it(), Aleph::DynDlist< T >::size(), and Aleph::to_array().
| TEST_F | ( | List_of_10_items | , |
| ConstReverseReturnsIndependentCopy | |||
| ) |
Definition at line 460 of file dyndlist.cc.
References LocateFunctions< Container, Type >::get_it(), Aleph::DynDlist< T >::rev(), and Aleph::DynDlist< T >::reverse().
| TEST_F | ( | List_of_10_items | , |
| copy_and_assignment | |||
| ) |
Definition at line 186 of file dyndlist.cc.
References Aleph::and, Aleph::DynDlist< T >::empty(), LocateFunctions< Container, Type >::get_it(), Aleph::Dlink::is_empty(), and Aleph::DynDlist< T >::size().
| TEST_F | ( | List_of_25_items | , |
| append_and_insert_by_moving | |||
| ) |
Definition at line 383 of file dyndlist.cc.
References Aleph::DynDlist< T >::insert(), Aleph::Dlink::is_empty(), and Aleph::DynDlist< T >::reverse().
| TEST_F | ( | List_of_25_items | , |
| Basic_operations | |||
| ) |
Definition at line 249 of file dyndlist.cc.
| TEST_F | ( | List_of_25_items | , |
| Iterator_operations | |||
| ) |
Definition at line 259 of file dyndlist.cc.
| TEST_F | ( | List_of_25_items | , |
| reverse | |||
| ) |
Definition at line 322 of file dyndlist.cc.
References l, r, and Aleph::DynList< T >::reverse().
| TEST_F | ( | List_of_25_items | , |
| rotate_left | |||
| ) |
Definition at line 351 of file dyndlist.cc.
| TEST_F | ( | List_of_25_items | , |
| rotate_right | |||
| ) |
Definition at line 367 of file dyndlist.cc.
| TEST_F | ( | List_of_25_items | , |
| Split_and_concat | |||
| ) |
Definition at line 281 of file dyndlist.cc.
References Aleph::DynList< T >::get_first(), LocateFunctions< Container, Type >::get_it(), Aleph::DynList< T >::get_last(), l, Aleph::Gsl_Compatible_Rng::next(), r, and Aleph::DynList< T >::size().
| TEST_F | ( | List_of_25_items | , |
| swap | |||
| ) |
Definition at line 308 of file dyndlist.cc.
References LocateFunctions< Container, Type >::get_it(), Aleph::Dlink::is_empty(), and Aleph::DynDlist< T >::swap().
| TEST_F | ( | List_of_25_items | , |
| traverse | |||
| ) |
Definition at line 410 of file dyndlist.cc.
References N.