Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
tree: 3aab8372df
Fetching contributors…

Cannot retrieve contributors at this time

25 lines (20 sloc) 0.647 kb
#!/usr/bin/env python
import agent_interact as A
def testDynamicImportMember1():
# Check with a function
relpath = A.DynamicImportMember("os.path.relpath")
import os.path
assert(relpath == os.path.relpath)
return
def testDynamicImportMember2():
# Check with a class
option_parser = A.DynamicImportMember("optparse.OptionParser")
import optparse
assert(option_parser == optparse.OptionParser)
return
def testDynamicImportMember3():
# Check with a snake_game module
import snake_game.pygame_artist as S
artist = A.DynamicImportMember("snake_game.pygame_artist.PyGameArtist")
assert(S.PyGameArtist == artist)
return
Jump to Line
Something went wrong with that request. Please try again.