COIN-OR::LEMON - Graph Library

source: lemon-0.x/src/test/graph_wrapper_test.cc @ 990:407e4d47fdd3

Last change on this file since 990:407e4d47fdd3 was 989:ca95f8b5c931, checked in by Balazs Dezso, 19 years ago

XyzConcept? moved to Xyz::Constraints
use checkConcept in the next way:

checkConcept<ErasableGraph?, ListGraph?>();
checkConcept<ReadWriteMap?<Node, Node>, PredMap?>;

File size: 2.0 KB
Line 
1/* -*- C++ -*-
2 * src/test/graph_wrapper_test.cc - Part of LEMON, a generic C++ optimization library
3 *
4 * Copyright (C) 2004 Egervary Jeno Kombinatorikus Optimalizalasi Kutatocsoport
5 * (Egervary Combinatorial Optimization Research Group, EGRES).
6 *
7 * Permission to use, modify and distribute this software is granted
8 * provided that this copyright notice appears in all copies. For
9 * precise terms see the accompanying LICENSE file.
10 *
11 * This software is provided "AS IS" with no warranty of any kind,
12 * express or implied, and with no claim as to its suitability for any
13 * purpose.
14 *
15 */
16
17#include<iostream>
18#include<lemon/concept_check.h>
19
20#include<lemon/smart_graph.h>
21#include<lemon/concept/graph.h>
22
23#include<lemon/list_graph.h>
24#include<lemon/full_graph.h>
25#include<lemon/graph_wrapper.h>
26
27#include"test/test_tools.h"
28#include"test/graph_test.h"
29
30/**
31\file
32This test makes consistency checks of graph wrappers.
33
34\todo More extensive tests are needed
35*/
36
37using namespace lemon;
38using namespace lemon::concept;
39
40
41
42int main()
43{
44  {
45    checkConcept<StaticGraph, GraphWrapper<StaticGraph> >();
46
47//     function_requires<StaticGraphConcept<RevGraphWrapper<Graph> > >();
48
49//     function_requires<StaticGraphConcept<SubGraphWrapper<Graph, Graph::NodeMap<bool> , Graph::EdgeMap<bool> > > >();
50//     function_requires<StaticGraphConcept<NodeSubGraphWrapper<Graph, Graph::NodeMap<bool> > > >();
51//     function_requires<StaticGraphConcept<EdgeSubGraphWrapper<Graph, Graph::EdgeMap<bool> > > >();
52
53//     function_requires<StaticGraphConcept<SubBidirGraphWrapper<Graph, Graph::EdgeMap<bool>, Graph::EdgeMap<bool> > > > ();
54
55//     function_requires<StaticGraphConcept<BidirGraph<Graph> > >();
56
57//     function_requires<StaticGraphConcept<ResGraphWrapper<Graph, int, Graph::EdgeMap<int>, Graph::EdgeMap<int> > > >();
58
59//     function_requires<StaticGraphConcept<ErasingFirstGraphWrapper<Graph, Graph::NodeMap<Graph::Edge> > > >();
60  }
61  std::cout << __FILE__ ": All tests passed.\n";
62
63  return 0;
64}
Note: See TracBrowser for help on using the repository browser.