mirror of https://github.com/scrapy/scrapy.git
test: reduce test data size to 1MB
This commit is contained in:
parent
4acdc2e5d6
commit
a94b30342a
|
|
@ -243,7 +243,6 @@ class Stream:
|
|||
bytes_to_send_size = min(window_size, self.remaining_content_length)
|
||||
|
||||
# We now need to send a number of data frames.
|
||||
data_frames_sent = 0
|
||||
while bytes_to_send_size > 0:
|
||||
chunk_size = min(bytes_to_send_size, max_frame_size)
|
||||
|
||||
|
|
@ -252,7 +251,6 @@ class Stream:
|
|||
|
||||
self._conn.send_data(self.stream_id, data_chunk, end_stream=False)
|
||||
|
||||
data_frames_sent += 1
|
||||
bytes_to_send_size = bytes_to_send_size - chunk_size
|
||||
self.remaining_content_length = self.remaining_content_length - chunk_size
|
||||
|
||||
|
|
|
|||
|
|
@ -42,8 +42,8 @@ def make_html_body(val):
|
|||
|
||||
|
||||
class Data:
|
||||
SMALL_SIZE = 1024 * 10 # 10 KB
|
||||
LARGE_SIZE = (1024 ** 2) * 10 # 10 MB
|
||||
SMALL_SIZE = 1024 # 1 KB
|
||||
LARGE_SIZE = 1024 ** 2 # 1 MB
|
||||
|
||||
STR_SMALL = generate_random_string(SMALL_SIZE)
|
||||
STR_LARGE = generate_random_string(LARGE_SIZE)
|
||||
|
|
|
|||
Loading…
Reference in New Issue