Sanitize existing suite names

When first suites were added, osmo-nitb was used. Then new tests using
regular split components were added with "aoip_" prefix. At some point
it was clear that osmo-nitb was being deprecated so new tests for split
components were added without any prefix, as they are expected to be the
default one. Since most current and future development is going to be done
for split components, as well as new tests added, it makes sense to move
the few old testsuites using osmo-nitb to have all "nitb_" prefix, while
keeping the split component tests without prefix as it's the regular
network topology.

Change-Id: Idea2e053d337548e0e9b1b47441dbb262124f909
diff --git a/suites/debug/error.py b/suites/debug/error.py
deleted file mode 100644
index 032e26c..0000000
--- a/suites/debug/error.py
+++ /dev/null
@@ -1,5 +0,0 @@
-#!/usr/bin/env python3
-from osmo_gsm_tester.testenv import *
-
-# This can be used to verify that a test error is reported properly.
-assert False
diff --git a/suites/debug/fail.py b/suites/debug/fail.py
deleted file mode 100644
index a2d9e3a..0000000
--- a/suites/debug/fail.py
+++ /dev/null
@@ -1,5 +0,0 @@
-#!/usr/bin/env python3
-from osmo_gsm_tester.testenv import *
-
-# This can be used to verify that a test failure is reported properly.
-test.set_fail('ExpectedFail', 'This failure is expected')
diff --git a/suites/debug/fail_raise.py b/suites/debug/fail_raise.py
deleted file mode 100644
index c30a4f5..0000000
--- a/suites/debug/fail_raise.py
+++ /dev/null
@@ -1,8 +0,0 @@
-#!/usr/bin/env python3
-from osmo_gsm_tester.testenv import *
-
-class ExpectedExn(Exception):
-    pass
-
-# This can be used to verify that a test failure is reported properly.
-raise ExpectedExn('This failure is expected')
diff --git a/suites/debug/interactive.py b/suites/debug/interactive.py
index 595cfd9..98bf174 100755
--- a/suites/debug/interactive.py
+++ b/suites/debug/interactive.py
@@ -1,23 +1,43 @@
 #!/usr/bin/env python3
 from osmo_gsm_tester.testenv import *
-
-print('use resources...')
-nitb = suite.nitb()
+hlr = suite.hlr()
 bts = suite.bts()
+pcu = bts.pcu()
+mgw_msc = suite.mgw()
+mgw_bsc = suite.mgw()
+stp = suite.stp()
+ggsn = suite.ggsn()
+sgsn = suite.sgsn(hlr, ggsn)
+msc = suite.msc(hlr, mgw_msc, stp)
+bsc = suite.bsc(msc, mgw_bsc, stp)
+
 modems = suite.modems(int(prompt('How many modems?')))
 
-print('start nitb and bts...')
-nitb.bts_add(bts)
-nitb.start()
+bsc.bts_add(bts)
+sgsn.bts_add(bts)
+
+hlr.start()
+stp.start()
+ggsn.start()
+sgsn.start()
+msc.start()
+mgw_msc.start()
+mgw_bsc.start()
+bsc.start()
+
 bts.start()
-wait(nitb.bts_is_connected, bts)
+print('Waiting for bts to connect to bsc...')
+wait(bsc.bts_is_connected, bts)
+print('Waiting for bts to be ready...')
+wait(bts.ready_for_pcu)
+pcu.start()
 
 for m in modems:
-  nitb.subscriber_add(m)
-  m.connect(nitb.mcc_mnc())
+  hlr.subscriber_add(m)
+  m.connect(msc.mcc_mnc())
 
 while True:
-  cmd = prompt('Enter command: (q)uit (s)ms (g)et-registered (w)ait-registered, call-list [<ms_msisdn>], call-dial <src_msisdn> <dst_msisdn>, call-wait-incoming <src_msisdn> <dst_msisdn>, call-answer <mt_msisdn> <call_id>, call-hangup <ms_msisdn> <call_id>, ussd <command>')
+  cmd = prompt('Enter command: (q)uit (s)ms (g)et-registered (w)ait-registered, call-list [<ms_msisdn>], call-dial <src_msisdn> <dst_msisdn>, call-wait-incoming <src_msisdn> <dst_msisdn>, call-answer <mt_msisdn> <call_id>, call-hangup <ms_msisdn> <call_id>, ussd <command>, data-attach, data-wait, data-detach, data-activate')
   cmd = cmd.strip().lower()
 
   if not cmd:
@@ -31,15 +51,15 @@
   elif 'wait-registered'.startswith(cmd):
     try:
       for m in modems:
-         wait(m.is_connected, nitb.mcc_mnc())
-      wait(nitb.subscriber_attached, *modems)
+          wait(m.is_connected, msc.mcc_mnc())
+      wait(msc.subscriber_attached, *modems)
     except Timeout:
       print('Timeout while waiting for registration.')
 
   elif 'get-registered'.startswith(cmd):
-    print(nitb.imsi_list_attached())
+    print(msc.imsi_list_attached())
     print('RESULT: %s' %
-       ('All modems are registered.' if nitb.subscriber_attached(*modems)
+       ('All modems are registered.' if msc.subscriber_attached(*modems)
         else 'Some modem(s) not registered yet.'))
 
   elif 'sms'.startswith(cmd):
@@ -107,5 +127,34 @@
         response = ms.ussd_send(ussd_cmd)
         print('modem %s: response=%r' % (ms.name(), response))
 
+  elif cmd.startswith('data-attach'):
+    if len(params) != 1:
+      print('wrong format')
+      continue
+    for ms in modems:
+        print('modem %s: attach' % ms.name())
+        ms.attach()
+        wait(ms.is_attached)
+        print('modem %s: attached' % ms.name())
+
+  elif cmd.startswith('data-detach'):
+    if len(params) != 1:
+      print('wrong format')
+      continue
+    for ms in modems:
+        print('modem %s: detach' % ms.name())
+        ms.attach()
+        wait(lambda: not ms.is_attached())
+        print('modem %s: detached' % ms.name())
+
+  elif cmd.startswith('data-activate'):
+    if len(params) != 1:
+      print('wrong format')
+      continue
+    for ms in modems:
+        print('modem %s: activate' % ms.name())
+        response = ms.activate_context()
+        print('modem %s: response=%r' % (ms.name(), response))
+
   else:
       print('Unknown command: %s' % cmd)
diff --git a/suites/debug/pass.py b/suites/debug/pass.py
deleted file mode 100644
index c07f079..0000000
--- a/suites/debug/pass.py
+++ /dev/null
@@ -1,5 +0,0 @@
-#!/usr/bin/env python3
-from osmo_gsm_tester.testenv import *
-
-# This can be used to verify that a test passes correctly.
-pass
diff --git a/suites/debug/suite.conf b/suites/debug/suite.conf
index adfc161..2f36e1d 100644
--- a/suites/debug/suite.conf
+++ b/suites/debug/suite.conf
@@ -1,10 +1,7 @@
 resources:
   ip_address:
-  - times: 1
+  - times: 8
   bts:
   - times: 1
   modem:
   - times: 4
-
-defaults:
-  timeout: 60s