From 02a518a0f3e9531f575ae9ee725fc1f57d8adf79 Mon Sep 17 00:00:00 2001 From: Claudio-Daniel Freire Date: Tue, 10 May 2011 10:53:02 +0200 Subject: [PATCH] Detect alternate NS3 installations (_ns3 module instead of ns3) --- test/lib/test_util.py | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/test/lib/test_util.py b/test/lib/test_util.py index 87e22c36..39fe983a 100644 --- a/test/lib/test_util.py +++ b/test/lib/test_util.py @@ -44,7 +44,11 @@ def ns3_usable(): found = imp.find_module('ns3') module = imp.load_module('ns3', *found) except ImportError: - return False + try: + found = imp.find_module('_ns3') + module = imp.load_module('_ns3', *found) + except ImportError: + return False finally: if ns3_bindings_path(): del sys.path[0] -- 2.45.2