build: add new .ns3rc message and table asserts/logs setting status

This commit is contained in:
Gabriel Ferreira
2023-01-22 12:15:21 -03:00
committed by Eduardo Almeida
parent af86afe102
commit edafe76036
2 changed files with 12 additions and 2 deletions

View File

@@ -113,12 +113,18 @@ function(print_formatted_table_with_modules table_name modules output)
endfunction()
macro(write_configtable)
set(out "---- Summary of optional ns-3 features:\n")
set(out "---- Summary of ns-3 settings:\n")
string(APPEND out "Build profile : ${build_profile}\n")
string(APPEND out
"Build directory : ${CMAKE_OUTPUT_DIRECTORY}\n"
)
string(APPEND out "Build with runtime asserts : ")
check_on_or_off("${NS3_ASSERT}" "${NS3_ASSERT}")
string(APPEND out "Build with runtime logging : ")
check_on_or_off("${NS3_LOG}" "${NS3_LOG}")
string(APPEND out "Build version embedding : ")
check_on_or_off("${NS3_ENABLE_BUILD_VERSION}" "${ENABLE_BUILD_VERSION}")
@@ -211,4 +217,8 @@ macro(write_configtable)
file(WRITE ${PROJECT_BINARY_DIR}/ns3config.txt ${out})
message(STATUS ${out})
if(NOT (${NS3RC} STREQUAL "NS3RC-NOTFOUND"))
message(STATUS "Applying configuration override from: ${NS3RC}")
endif()
endmacro()

View File

@@ -1173,7 +1173,7 @@ class NS3ConfigureTestCase(NS3BaseTestCase):
"""
return_code, stdout, stderr = run_ns3("show config")
self.assertEqual(return_code, 0)
self.assertIn("Summary of optional ns-3 features", stdout)
self.assertIn("Summary of ns-3 settings", stdout)
def test_11_CheckProfile(self):
"""!