blob: 10222e8446ebbc763a0f465413e1b3ee6970114e [file] [log] [blame]
Ashlesh Gawandeeb582eb2014-05-01 14:25:20 -05001/**
2 * Copyright (C) 2014 Regents of the University of Memphis.
3 * See COPYING for copyright and distribution information.
4 */
5
6#include "route/nexthop-list.hpp"
7#include "route/nexthop.hpp"
8#include <boost/test/unit_test.hpp>
9
10namespace nlsr {
11
12namespace test {
13
14BOOST_AUTO_TEST_SUITE(TestNhl)
15
16BOOST_AUTO_TEST_CASE(NhlAddNextHop)
17{
18 NextHop np1;
19
20 NexthopList nhl1;
21
22 nhl1.addNextHop(np1);
23 BOOST_CHECK_EQUAL(nhl1.getSize(), 1);
24
25 nhl1.removeNextHop(np1);
26 BOOST_CHECK_EQUAL(nhl1.getSize(), 0);
27}
28
29BOOST_AUTO_TEST_SUITE_END()
30
31} //namespace test
32} //namespace nlsr