Replaced import of the 'new' module with 'types' module and added a deprecation warning to the 'new' module.
diff --git a/Lib/test/test_getopt.py b/Lib/test/test_getopt.py
index a3a9940..36d1688 100644
--- a/Lib/test/test_getopt.py
+++ b/Lib/test/test_getopt.py
@@ -167,8 +167,8 @@
         ['a1', 'a2']
         """
 
-        import new
-        m = new.module("libreftest", s)
+        import types
+        m = types.ModuleType("libreftest", s)
         run_doctest(m, verbose)