MyraMath
RandomAccessList


Source: tests/multifrontal/symbolic/RandomAccessList.cpp

1 // ========================================================================= //
2 // This file is part of MyraMath, copyright (c) 2014-2019 by Ryan A Chilton //
3 // and distributed by MyraCore, LLC. See LICENSE.txt for license terms. //
4 // ========================================================================= //
5 
11 // Containers.
12 #include <myramath/multifrontal/symbolic/detail/RandomAccessList.h>
13 
14 // Reporting.
15 #include <tests/myratest.h>
17 #include <map>
18 #include <set>
19 
20 using namespace myra;
21 
22 // Tests some arbitrary insert() / erase() operations.
23 ADD_TEST("RandomAccessList","[symbolic]")
24  {
25  int N = 100;
26  RandomAccessList list(N);
27  list.insert(22);
28  list.insert(78);
29  list.insert(43);
30  list.insert(37);
31  list.erase(43);
32  REQUIRE( list.size() == 3);
33  REQUIRE( list.contains(22) );
34  REQUIRE( list.contains(78) );
35  REQUIRE( list.contains(37) );
36  }
37 
Definition: syntax.dox:1
Routines for printing the contents of various std::container&#39;s to a std::ostream using operator <<...


Results: [PASS]


Go back to Summary of /test programs.