A Discrete-Event Network Simulator
API
Loading...
Searching...
No Matches
test-ns3.NS3ExpectedUseTestCase Class Reference

Tests ns3 usage in more realistic scenarios. More...

+ Inheritance diagram for test-ns3.NS3ExpectedUseTestCase:
+ Collaboration diagram for test-ns3.NS3ExpectedUseTestCase:

Public Member Functions

def setUp (self)
 Reuse cleaning/release configuration from NS3BaseTestCase if flag is cleaned Here examples, tests and documentation are also enabled.
 
def test_01_BuildProject (self)
 Try to build the project.
 
def test_02_BuildAndRunExistingExecutableTarget (self)
 Try to build and run test-runner.
 
def test_03_BuildAndRunExistingLibraryTarget (self)
 Try to build and run a library.
 
def test_04_BuildAndRunNonExistingTarget (self)
 Try to build and run an unknown target.
 
def test_05_RunNoBuildExistingExecutableTarget (self)
 Try to run test-runner without building.
 
def test_06_RunNoBuildExistingLibraryTarget (self)
 Test ns3 fails to run a library.
 
def test_07_RunNoBuildNonExistingExecutableTarget (self)
 Test ns3 fails to run an unknown program.
 
def test_08_RunNoBuildGdb (self)
 Test if scratch simulator is executed through gdb and lldb.
 
def test_09_RunNoBuildValgrind (self)
 Test if scratch simulator is executed through valgrind.
 
def test_10_DoxygenWithBuild (self)
 Test the doxygen target that does trigger a full build.
 
def test_11_DoxygenWithoutBuild (self)
 Test the doxygen target that doesn't trigger a full build.
 
def test_12_SphinxDocumentation (self)
 Test every individual target for Sphinx-based documentation.
 
def test_13_Documentation (self)
 Test the documentation target that builds both doxygen and sphinx based documentation.
 
def test_14_EnableSudo (self)
 Try to set ownership of scratch-simulator from current user to root, and change execution permissions.
 
def test_15_CommandTemplate (self)
 Check if command template is working.
 
def test_16_ForwardArgumentsToRunTargets (self)
 Check if all flavors of different argument passing to executable targets are working.
 
def test_17_RunNoBuildLldb (self)
 Test if scratch simulator is executed through lldb.
 
def test_18_CpmAndVcpkgManagers (self)
 Test if CPM and Vcpkg package managers are working properly.
 
- Public Member Functions inherited from test-ns3.NS3BaseTestCase
def config_ok (self, return_code, stdout, stderr)
 Check if configuration for release mode worked normally.
 
def setUp (self)
 Clean configuration/build artifacts before testing configuration and build settings After configuring the build as release, check if configuration worked and check expected output files.
 

Public Attributes

 ns3_executables
 ns3_executables holds a list of executables in .lock-ns3 # noqa
 
 ns3_modules
 ns3_modules holds a list to the modules enabled stored in .lock-ns3 # noqa
 
- Public Attributes inherited from test-ns3.NS3BaseTestCase
 ns3_executables
 ns3_executables holds a list of executables in .lock-ns3 # noqa
 
 ns3_modules
 ns3_modules holds a list to the modules enabled stored in .lock-ns3 # noqa
 

Detailed Description

Tests ns3 usage in more realistic scenarios.

Definition at line 2634 of file test-ns3.py.

Member Function Documentation

◆ setUp()

def test-ns3.NS3ExpectedUseTestCase.setUp (   self)

Reuse cleaning/release configuration from NS3BaseTestCase if flag is cleaned Here examples, tests and documentation are also enabled.

Returns
None

Reimplemented from test-ns3.NS3BaseTestCase.

Definition at line 2639 of file test-ns3.py.

References test-ns3.NS3BaseTestCase.config_ok(), test-ns3.run_ns3(), and test-ns3.NS3ExpectedUseTestCase.setUp().

Referenced by test-ns3.NS3ExpectedUseTestCase.setUp().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ test_01_BuildProject()

def test-ns3.NS3ExpectedUseTestCase.test_01_BuildProject (   self)

Try to build the project.

Returns
None

Definition at line 2666 of file test-ns3.py.

References test-ns3.get_enabled_modules(), test-ns3.get_libraries_list(), test-ns3.get_programs_list(), and test-ns3.run_ns3().

+ Here is the call graph for this function:

◆ test_02_BuildAndRunExistingExecutableTarget()

def test-ns3.NS3ExpectedUseTestCase.test_02_BuildAndRunExistingExecutableTarget (   self)

Try to build and run test-runner.

Returns
None

Definition at line 2681 of file test-ns3.py.

References test-ns3.cmake_build_target_command, and test-ns3.run_ns3().

+ Here is the call graph for this function:

◆ test_03_BuildAndRunExistingLibraryTarget()

def test-ns3.NS3ExpectedUseTestCase.test_03_BuildAndRunExistingLibraryTarget (   self)

Try to build and run a library.

Returns
None

Definition at line 2691 of file test-ns3.py.

References test-ns3.run_ns3().

+ Here is the call graph for this function:

◆ test_04_BuildAndRunNonExistingTarget()

def test-ns3.NS3ExpectedUseTestCase.test_04_BuildAndRunNonExistingTarget (   self)

Try to build and run an unknown target.

Returns
None

Definition at line 2700 of file test-ns3.py.

References test-ns3.run_ns3().

+ Here is the call graph for this function:

◆ test_05_RunNoBuildExistingExecutableTarget()

def test-ns3.NS3ExpectedUseTestCase.test_05_RunNoBuildExistingExecutableTarget (   self)

Try to run test-runner without building.

Returns
None

Definition at line 2709 of file test-ns3.py.

References test-ns3.cmake_build_target_command, and test-ns3.run_ns3().

+ Here is the call graph for this function:

◆ test_06_RunNoBuildExistingLibraryTarget()

def test-ns3.NS3ExpectedUseTestCase.test_06_RunNoBuildExistingLibraryTarget (   self)

Test ns3 fails to run a library.

Returns
None

Definition at line 2722 of file test-ns3.py.

References test-ns3.run_ns3().

+ Here is the call graph for this function:

◆ test_07_RunNoBuildNonExistingExecutableTarget()

def test-ns3.NS3ExpectedUseTestCase.test_07_RunNoBuildNonExistingExecutableTarget (   self)

Test ns3 fails to run an unknown program.

Returns
None

Definition at line 2731 of file test-ns3.py.

References test-ns3.run_ns3().

+ Here is the call graph for this function:

◆ test_08_RunNoBuildGdb()

def test-ns3.NS3ExpectedUseTestCase.test_08_RunNoBuildGdb (   self)

Test if scratch simulator is executed through gdb and lldb.

Returns
None

Definition at line 2740 of file test-ns3.py.

References test-ns3.run_ns3().

+ Here is the call graph for this function:

◆ test_09_RunNoBuildValgrind()

def test-ns3.NS3ExpectedUseTestCase.test_09_RunNoBuildValgrind (   self)

Test if scratch simulator is executed through valgrind.

Returns
None

Definition at line 2761 of file test-ns3.py.

References test-ns3.run_ns3().

+ Here is the call graph for this function:

◆ test_10_DoxygenWithBuild()

def test-ns3.NS3ExpectedUseTestCase.test_10_DoxygenWithBuild (   self)

Test the doxygen target that does trigger a full build.

Returns
None

Definition at line 2779 of file test-ns3.py.

References test-ns3.cmake_build_target_command, and test-ns3.run_ns3().

+ Here is the call graph for this function:

◆ test_11_DoxygenWithoutBuild()

def test-ns3.NS3ExpectedUseTestCase.test_11_DoxygenWithoutBuild (   self)

Test the doxygen target that doesn't trigger a full build.

Returns
None

Definition at line 2808 of file test-ns3.py.

References test-ns3.cmake_build_target_command, and test-ns3.run_ns3().

+ Here is the call graph for this function:

◆ test_12_SphinxDocumentation()

def test-ns3.NS3ExpectedUseTestCase.test_12_SphinxDocumentation (   self)

Test every individual target for Sphinx-based documentation.

Returns
None

Definition at line 2827 of file test-ns3.py.

References test-ns3.cmake_build_target_command, and test-ns3.run_ns3().

+ Here is the call graph for this function:

◆ test_13_Documentation()

def test-ns3.NS3ExpectedUseTestCase.test_13_Documentation (   self)

Test the documentation target that builds both doxygen and sphinx based documentation.

Returns
None

Definition at line 2861 of file test-ns3.py.

References test-ns3.cmake_build_target_command, and test-ns3.run_ns3().

+ Here is the call graph for this function:

◆ test_14_EnableSudo()

def test-ns3.NS3ExpectedUseTestCase.test_14_EnableSudo (   self)

Try to set ownership of scratch-simulator from current user to root, and change execution permissions.

Returns
None

Definition at line 2893 of file test-ns3.py.

References test-ns3.cmake_build_target_command, list, test-ns3.NS3BaseTestCase.ns3_executables, test-ns3.NS3BuildBaseTestCase.ns3_executables, test-ns3.NS3ExpectedUseTestCase.ns3_executables, test-ns3.read_lock_entry(), and test-ns3.run_ns3().

+ Here is the call graph for this function:

◆ test_15_CommandTemplate()

def test-ns3.NS3ExpectedUseTestCase.test_15_CommandTemplate (   self)

Check if command template is working.

Returns
None

Definition at line 2976 of file test-ns3.py.

References test-ns3.run_ns3().

+ Here is the call graph for this function:

◆ test_16_ForwardArgumentsToRunTargets()

def test-ns3.NS3ExpectedUseTestCase.test_16_ForwardArgumentsToRunTargets (   self)

Check if all flavors of different argument passing to executable targets are working.

Returns
None

Definition at line 3006 of file test-ns3.py.

References test-ns3.run_ns3().

+ Here is the call graph for this function:

◆ test_17_RunNoBuildLldb()

def test-ns3.NS3ExpectedUseTestCase.test_17_RunNoBuildLldb (   self)

Test if scratch simulator is executed through lldb.

Returns
None

Definition at line 3070 of file test-ns3.py.

References test-ns3.run_ns3().

+ Here is the call graph for this function:

◆ test_18_CpmAndVcpkgManagers()

def test-ns3.NS3ExpectedUseTestCase.test_18_CpmAndVcpkgManagers (   self)

Test if CPM and Vcpkg package managers are working properly.

Returns
None

Definition at line 3086 of file test-ns3.py.

References test-ns3.run_ns3().

+ Here is the call graph for this function:

Member Data Documentation

◆ ns3_executables

test-ns3.NS3ExpectedUseTestCase.ns3_executables

◆ ns3_modules


The documentation for this class was generated from the following file: