utils/run-tests.cc
author Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
Thu, 13 Mar 2008 12:56:49 -0700
changeset 2602 d9262bff6df2
parent 1806 34e115600ef2
child 2834 1aab57845b07
permissions -rw-r--r--
add back support for introspected doxygen.
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
150
663120712cd9 fix coding style
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents: 131
diff changeset
     1
/* -*- Mode:C++; c-file-style:"gnu"; indent-tabs-mode:nil; -*- */
12
917ba023c576 utils and samples
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff changeset
     2
/*
917ba023c576 utils and samples
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff changeset
     3
 * Copyright (c) 2005 INRIA
917ba023c576 utils and samples
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff changeset
     4
 * All rights reserved.
917ba023c576 utils and samples
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff changeset
     5
 *
917ba023c576 utils and samples
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff changeset
     6
 * This program is free software; you can redistribute it and/or modify
917ba023c576 utils and samples
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff changeset
     7
 * it under the terms of the GNU General Public License version 2 as
917ba023c576 utils and samples
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff changeset
     8
 * published by the Free Software Foundation;
917ba023c576 utils and samples
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff changeset
     9
 *
917ba023c576 utils and samples
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff changeset
    10
 * This program is distributed in the hope that it will be useful,
917ba023c576 utils and samples
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff changeset
    11
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
917ba023c576 utils and samples
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff changeset
    12
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
917ba023c576 utils and samples
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff changeset
    13
 * GNU General Public License for more details.
917ba023c576 utils and samples
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff changeset
    14
 *
917ba023c576 utils and samples
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff changeset
    15
 * You should have received a copy of the GNU General Public License
917ba023c576 utils and samples
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff changeset
    16
 * along with this program; if not, write to the Free Software
917ba023c576 utils and samples
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff changeset
    17
 * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
917ba023c576 utils and samples
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff changeset
    18
 *
917ba023c576 utils and samples
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff changeset
    19
 * Author: Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
917ba023c576 utils and samples
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff changeset
    20
 */
917ba023c576 utils and samples
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff changeset
    21
14
6dd7d31c6fc3 replace yans include with ns3 include
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents: 12
diff changeset
    22
#include "ns3/test.h"
1526
46623ec253f4 Need to enable packet metadata early, else we trigger an assertion.
Gustavo J. A. M. Carneiro <gjc@inescporto.pt>
parents: 437
diff changeset
    23
#include "ns3/packet-metadata.h"
1806
34e115600ef2 Fixed randomvariable bugs and modified unit tests so that there is no non-deterministic failure on the tests
Raj Bhattacharjea <raj.b@gatech.edu>
parents: 1526
diff changeset
    24
#include "ns3/random-variable.h"
1526
46623ec253f4 Need to enable packet metadata early, else we trigger an assertion.
Gustavo J. A. M. Carneiro <gjc@inescporto.pt>
parents: 437
diff changeset
    25
12
917ba023c576 utils and samples
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff changeset
    26
917ba023c576 utils and samples
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff changeset
    27
int main (int argc, char *argv[])
917ba023c576 utils and samples
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff changeset
    28
{
917ba023c576 utils and samples
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff changeset
    29
#ifdef RUN_SELF_TESTS
1806
34e115600ef2 Fixed randomvariable bugs and modified unit tests so that there is no non-deterministic failure on the tests
Raj Bhattacharjea <raj.b@gatech.edu>
parents: 1526
diff changeset
    30
  ns3::RandomVariable::UseGlobalSeed(1,2,3,4,5,6);
1526
46623ec253f4 Need to enable packet metadata early, else we trigger an assertion.
Gustavo J. A. M. Carneiro <gjc@inescporto.pt>
parents: 437
diff changeset
    31
  ns3::PacketMetadata::Enable ();
150
663120712cd9 fix coding style
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents: 131
diff changeset
    32
  ns3::TestManager::EnableVerbose ();
437
b2169abd3451 Provide correct exit value based on RunTests() success
Tom Henderson <tomh@tomh.org>
parents: 150
diff changeset
    33
  bool success = ns3::TestManager::RunTests ();
b2169abd3451 Provide correct exit value based on RunTests() success
Tom Henderson <tomh@tomh.org>
parents: 150
diff changeset
    34
  if (!success)
b2169abd3451 Provide correct exit value based on RunTests() success
Tom Henderson <tomh@tomh.org>
parents: 150
diff changeset
    35
    return 1;
12
917ba023c576 utils and samples
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff changeset
    36
#endif /* RUN_SELF_TESTS */
917ba023c576 utils and samples
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff changeset
    37
150
663120712cd9 fix coding style
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents: 131
diff changeset
    38
  return 0;
12
917ba023c576 utils and samples
Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
parents:
diff changeset
    39
}