Skip to content

Commit 81ead6e

Browse files
committed
Fix typo in name adjacenct_vertices.
1 parent 158eebd commit 81ead6e

File tree

2 files changed

+28
-4
lines changed

2 files changed

+28
-4
lines changed

include/boost/graph/labeled_graph.hpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -784,7 +784,7 @@ inline typename LABELED_GRAPH::degree_size_type degree(
784784
template < LABELED_GRAPH_PARAMS >
785785
inline std::pair< typename LABELED_GRAPH::adjacency_iterator,
786786
typename LABELED_GRAPH::adjacency_iterator >
787-
adjacenct_vertices(
787+
adjacent_vertices(
788788
typename LABELED_GRAPH::vertex_descriptor v, LABELED_GRAPH const& g)
789789
{
790790
return adjacent_vertices(v, g.graph());

test/labeled_graph.cpp

Lines changed: 27 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -4,23 +4,23 @@
44
// Boost Software License, Version 1.0 (See accompanying file
55
// LICENSE_1_0.txt or http://www.boost.org/LICENSE_1_0.txt)
66

7-
#include <iostream>
87
#include <string>
9-
#include <set>
108

119
#include <boost/assert.hpp>
10+
#include <boost/concept/assert.hpp>
1211
#include <boost/range.hpp>
1312

13+
#include <boost/graph/graph_concepts.hpp>
1414
#include <boost/graph/undirected_graph.hpp>
1515
#include <boost/graph/directed_graph.hpp>
1616
#include <boost/graph/labeled_graph.hpp>
1717

1818
#include "typestr.hpp"
1919

20-
using std::cout;
2120
using std::string;
2221
using namespace boost;
2322

23+
void test_concepts();
2424
void test_norm();
2525
void test_temp();
2626
void test_bacon();
@@ -29,13 +29,37 @@ void test_multiple_associative_container();
2929

3030
int main()
3131
{
32+
test_concepts();
3233
test_norm();
3334
test_temp();
3435
test_bacon();
3536
test_remove_labeled_vertex();
3637
test_multiple_associative_container();
3738
}
3839

40+
//////////////////////////////////////
41+
// Graph Concepts
42+
//////////////////////////////////////
43+
44+
void test_concepts()
45+
{
46+
// The labeled mutable graph hides the add_ and remove_ vertex functions
47+
// from the mutable graph concept, so VertexMutableGraphConcept will not be
48+
// tested here.
49+
{
50+
typedef labeled_graph< directed_graph<>, unsigned > Graph;
51+
BOOST_CONCEPT_ASSERT((VertexListGraphConcept< Graph >));
52+
BOOST_CONCEPT_ASSERT((AdjacencyGraphConcept< Graph >));
53+
BOOST_CONCEPT_ASSERT((EdgeMutableGraphConcept< Graph >));
54+
}
55+
{
56+
typedef labeled_graph< undirected_graph<>, unsigned > Graph;
57+
BOOST_CONCEPT_ASSERT((VertexListGraphConcept< Graph >));
58+
BOOST_CONCEPT_ASSERT((AdjacencyGraphConcept< Graph >));
59+
BOOST_CONCEPT_ASSERT((EdgeMutableGraphConcept< Graph >));
60+
}
61+
}
62+
3963
//////////////////////////////////////
4064
// Utility Functions and Types
4165
//////////////////////////////////////

0 commit comments

Comments
 (0)