Change more tests to use import_module for the modules that
should cause tests to be skipped. Also rename import_function
to the more descriptive get_attribute and add a docstring.
diff --git a/Lib/test/test_resource.py b/Lib/test/test_resource.py
index f354a1b..52692a7 100644
--- a/Lib/test/test_resource.py
+++ b/Lib/test/test_resource.py
@@ -1,9 +1,9 @@
import unittest
from test import test_support
-
-import resource
import time
+resource = test_support.import_module('resource')
+
# This test is checking a few specific problem spots with the resource module.
class ResourceTest(unittest.TestCase):