/* IterChainSearch(Test) - verify chained search operations with backtracking Copyright (C) Lumiera.org 2018, Hermann Vosseler This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation; either version 2 of the License, or (at your option) any later version. This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details. You should have received a copy of the GNU General Public License along with this program; if not, write to the Free Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. * *****************************************************/ /** @file iter-chain-search-test.cpp ** unit test \ref IterChainSearch_test */ #include "lib/test/run.hpp" #include "lib/test/test-helper.hpp" #include "lib/format-util.hpp" /////////////////////////////TODO necessary? #include "lib/format-cout.hpp" /////////////////////////////TODO necessary? #include "lib/iter-chain-search.hpp" #include "lib/util.hpp" #include #include namespace lib { namespace iter{ namespace test{ using ::Test; using util::join; using util::isnil; using util::isSameObject; using std::vector; using std::string; using lumiera::error::LERR_(ITER_EXHAUST); namespace { // test fixture using Spam = vector; const Spam SPAM{"spam" ,"sausage" ,"spam" ,"spam" ,"bacon" ,"spam" ,"tomato" ,"and" ,"spam" }; } // (END)fixture ///////////////////////////////////////////////////TODO WIP #define SHOW_TYPE(_TY_) \ cout << "typeof( " << STRINGIFY(_TY_) << " )= " << lib::meta::typeStr<_TY_>() <