Source

rope_py3k / ropetest / advanced_oi_test.py

Diff from to

File ropetest/advanced_oi_test.py

         pymod = self.pycore.resource_to_pyobject(mod)
         self.assertEquals(pymod['AClass'].get_object(),
                           pymod['a_var'].get_object())
-
+    
     def test_nested_classes(self):
         mod = testutils.create_module(self.project, 'mod')
         code = 'def a_func():\n    class AClass(object):\n' \
         self.assertEquals(pyscope.get_scopes()[0]['AClass'].get_object(),
                           pyscope['a_var'].get_object())
 
+    
     def test_function_argument_dti2(self):
         mod = testutils.create_module(self.project, 'mod')
         code = 'def a_func(arg, a_builtin_type):\n    pass\n' \
         mod = testutils.create_module(self.project, 'mod')
         code = 'class C(object):\n    pass\n' \
                'def a_func(arg):\n    return eval("arg")\n' \
-               'a_var = a_func({C(): 1}).keys()[0]\n'
+               'a_var = list(a_func({C(): 1}).keys())[0]\n'
         mod.write(code)
         self.pycore.run_module(mod).wait_process()
         pymod = self.pycore.resource_to_pyobject(mod)
         pymod2 = self.pycore.resource_to_pyobject(mod2)
         self.assertEquals(pymod2['C'].get_object(),
                           pymod['a_var'].get_object())
-
+    
 
 class NewStaticOITest(unittest.TestCase):