Beispiel #1
0
	def test_rand_bot(self, iter):
		network_excs = urllib.error.URLError, requests.exceptions.RequestException
		try:
			res = commands.rand_bot('#test', 'testrunner', '')
		except network_excs:
			if not pytest.config.has_internet:
				raise pytest.skip("Error suppressed for limited connectivity")
			raise
		if res is None:
			return
		if not isinstance(res, str):
			res = ''.join(res)
		assert len(res)
Beispiel #2
0
	def test_rand_bot(self, iter):
		network_excs = urllib.error.URLError, requests.exceptions.RequestException
		try:
			res = commands.rand_bot('#test', 'testrunner', '')
		except network_excs:
			if not pytest.config.has_internet:
				raise pytest.skip("Error suppressed for limited connectivity")
			raise
		if res is None:
			return
		if not isinstance(res, str):
			res = ''.join(res)
		assert len(res)
Beispiel #3
0
	def test_rand_bot(self, iter_):
		res = commands.rand_bot(c, e, '#test', 'testrunner', '')
		if res is None: return
		if not isinstance(res, basestring):
			res = u''.join(res)
		assert len(res)