我无法在我的第二个类中调用我的原始硒实例,它有一个函数GetRows()。有什么方法可以在我的函数类中获得硒对象?如何将Selenium对象传递给另一个类?
Class test(unittest.TestCase):
def setUp(self):
self.verificationerrors=[]
self.selenium = selenium("localhost",4444,"","http://localhost")
self.selenium.start()
def test_untitiled(self):
pass
def teardown(self):
pass
def Get(self):
return self.selenium
Class Functions:
def GetRows(self)
selenium.get_xpath_count(path) //Cant call selenium object here! :(
sel = test().get() // Does not allow me to return self. selenium :(
作为硒核心提交者我不能建议任何人使用SQA StackExchange。 -1 – AutomatedTester 2011-05-21 18:15:38
作为Selenium Doc的核心成员,我想我没有做错任何事情。你见过这个吗? - http://meta.sqa.stackexchange.com/questions/13/how-would-we-attract-selenium-users-to-ask-question-on-sqa-site-than-on-stackovef最重要的是这可能是将回答标记为-1的原因吗? – Tarun 2011-05-22 10:22:54