mirror of
https://github.com/valitydev/yandex-tank.git
synced 2024-11-06 10:25:17 +00:00
parent
fec8a0ebc6
commit
76a3084f12
@ -134,12 +134,25 @@ class StepperTestCase(TankTestCase):
|
||||
rps_schedule=[],
|
||||
instances_schedule=[],
|
||||
loop_limit=-1,
|
||||
ammo_limit=100,
|
||||
ammo_limit=10,
|
||||
ammo_type='access',
|
||||
headers=[],
|
||||
ammo_file="data/access1.log",
|
||||
).write(stpd_file)
|
||||
res = open(temp_stpd, 'r').read()
|
||||
# TODO: enable asserts after fixing the exception
|
||||
#self.assertNotEquals("", res)
|
||||
#self.assertEquals(126, os.path.getsize(temp_stpd))
|
||||
self.assertNotEquals("", res)
|
||||
self.assertEquals(1459, os.path.getsize(temp_stpd))
|
||||
|
||||
def test_empty_uri(self):
|
||||
from Tank.stepper.module_exceptions import AmmoFileError
|
||||
temp_stpd = tempfile.mkstemp()[1]
|
||||
with open(temp_stpd, 'w') as stpd_file:
|
||||
Stepper(
|
||||
rps_schedule=[],
|
||||
instances_schedule=[],
|
||||
loop_limit=-1,
|
||||
ammo_limit=10,
|
||||
headers=[],
|
||||
ammo_file="data/empty.uri",
|
||||
).write(stpd_file)
|
||||
self.assertRaises(AmmoFileError)
|
Loading…
Reference in New Issue
Block a user