Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Browse files

Refs #21628 -- removed one usage of the imp module in the tests. It i…

…s deprecated in Python 3.4
  • Loading branch information...
commit 9d487ae2a16d1efd501e65c78e6885c8cdcd4421 1 parent 10e0cfc
@alex alex authored
Showing with 2 additions and 2 deletions.
  1. +2 −2 tests/template_tests/test_loaders.py
View
4 tests/template_tests/test_loaders.py
@@ -9,9 +9,9 @@
if __name__ == '__main__':
settings.configure()
-import imp
import os.path
import sys
+import types
import unittest
try:
@@ -41,7 +41,7 @@ def create_egg(name, resources):
name: The name of the module.
resources: A dictionary of resources. Keys are the names and values the data.
"""
- egg = imp.new_module(name)
+ egg = types.ModuleType(name)
egg.__loader__ = MockLoader()
egg._resources = resources
sys.modules[name] = egg
Please sign in to comment.
Something went wrong with that request. Please try again.