Django's LiveServerTestCase Always Fails Due to Conflicting Address… Despite Address Appearing Free

前端 未结 5 1228
心在旅途
心在旅途 2020-12-31 05:45

I\'m currently working on cleaning my Django functional tests to use the LiveServerTestCase rather than bouncing selenium based tests off an instance of the development envi

5条回答
  •  天命终不由人
    2020-12-31 06:10

    Change your teardown method if you're going to separate your test cases

    Testing in one file is okay to use the .close() method

    def tearDown(self):
        self.browser.close()
    

    Testing in multiple files will require starting new threads.

    def tearDown(self):
        self.browser.quit()
    

提交回复
热议问题