views:

34

answers:

1

Assume a web page that returns binary content: http://localhost/website/Default.aspx?FileId=value

and we have some files with known Ids and checksums (i.e. MD5). How it's possible to extract whole response and calculate it's check-sum via some visual studio webtest ?

A: 

Have you tried the property this.Context.LastResponse.BodyBytes after you yield the webtestrequest?

A custom validation rule may be the way to go to calculate that the hash matches the content.

Nat
Yes I did. My response is a huge file and this method just returns < 50 MB. I need abou 1 GB of response.
Xaqron
Sorry, I've got nothing. Perhaps it would be possible to override the correct part of a WebtestRequest and pull the full file a piece at a time, but I have not found anything using .Net Reflector that seems to be appropriate.
Nat