A Discrete-Event Network Simulator
API
Loading...
Searching...
No Matches
internet-traced-callback-typedef-test-suite.cc
Go to the documentation of this file.
1/*
2 * Copyright (c) 2015 Lawrence Livermore National Laboratory
3 *
4 * SPDX-License-Identifier: GPL-2.0-only
5 *
6 * Author: Peter D. Barnes, Jr. <pdbarnes@llnl.gov>
7 */
8
9#include "ns3/ipv4-l3-protocol.h"
10#include "ns3/ipv6-l3-protocol.h"
11#include "ns3/traced-callback-typedef-test.h"
12
13/**
14 * @file
15 * @ingroup internet-test
16 *
17 * Verify that the TracedCallback typedefs declared by the internet module are
18 * invoked with the right type and number of arguments.
19 */
20
21namespace ns3
22{
23
24#ifndef DOXYGEN_SHOULD_SKIP_THIS
31#endif // DOXYGEN_SHOULD_SKIP_THIS
32
33/**
34 * @ingroup internet-test
35 *
36 * TracedCallback typedef Testcase for the internet module.
37 */
39{
40 public:
42
43 private:
44 void DoRun() override;
45};
46
51
52void
89
90/**
91 * @ingroup internet-test
92 *
93 * @brief internet TracedCallback typedef TestSuite
94 */
100
106
107/// Static variable for test initialization
109
110} // namespace ns3
TracedCallback typedef Testcase for the internet module.
void DoRun() override
Implementation to actually run this TestCase.
Packet header for IPv4.
Definition ipv4-header.h:23
DropReason
Reason why a packet has been dropped.
void(* DropTracedCallback)(const Ipv4Header &header, Ptr< const Packet > packet, DropReason reason, Ptr< Ipv4 > ipv4, uint32_t interface)
TracedCallback signature for packet drop events.
void(* TxRxTracedCallback)(Ptr< const Packet > packet, Ptr< Ipv4 > ipv4, uint32_t interface)
TracedCallback signature for packet transmission or reception events.
void(* SentTracedCallback)(const Ipv4Header &header, Ptr< const Packet > packet, uint32_t interface)
TracedCallback signature for packet send, forward, or local deliver events.
Packet header for IPv6.
Definition ipv6-header.h:24
void(* SentTracedCallback)(const Ipv6Header &header, Ptr< const Packet > packet, uint32_t interface)
TracedCallback signature for packet sent, forwarded or local-delivered events.
DropReason
Reason why a packet has been dropped.
void(* DropTracedCallback)(const Ipv6Header &header, Ptr< const Packet > packet, DropReason reason, Ptr< Ipv6 > ipv6, uint32_t interface)
TracedCallback signature for packet drop events.
void(* TxRxTracedCallback)(Ptr< const Packet > packet, Ptr< Ipv6 > ipv6, uint32_t interface)
TracedCallback signature for packet transmission or reception events.
Smart pointer class similar to boost::intrusive_ptr.
Definition ptr.h:70
void AddTestCase(TestCase *testCase, Duration duration=Duration::QUICK)
Add an individual child TestCase to this test suite.
Definition test.cc:296
@ QUICK
Fast test.
Definition test.h:1057
Type
Type of test.
Definition test.h:1271
TestSuite(std::string name, Type type=Type::UNIT)
Construct a new test suite.
Definition test.cc:494
TracedCallbackTypedefTestCase(std::string name)
Constructor.
#define TRACED_CALLBACK_CHECK(U,...)
Check the TracedCallback by calling its Invoke function.
#define TRACED_CALLBACK_TYPENAME(T)
Declare the stringified name of a TracedCallback typedef.
Every class exported by the ns3 library is enclosed in the ns3 namespace.
static InternetTracedCallbackTypedefTestSuite g_internetTracedCallbackTypedefTestSuite
Static variable for test initialization.