Skip to content

Instantly share code, notes, and snippets.

@wattengard
Created June 23, 2013 21:44
Show Gist options
  • Save wattengard/5846658 to your computer and use it in GitHub Desktop.
Save wattengard/5846658 to your computer and use it in GitHub Desktop.
var watch = new System.Diagnostics.Stopwatch();
var wc = new System.Net.WebClient();
System.Console.WriteLine("Starting download");
watch.Start();
var res = wc.DownloadData(@"http://ftp.sunet.se/pub/os/Linux/kernels/v3.x/linux-3.0.1.tar.gz");
watch.Stop();
System.Console.WriteLine("Done");
var w = File.AppendText("testscript.log");
w.WriteLine(String.Format("\"{0}\",{1},\"{2}\"", System.DateTime.Now, watch.ElapsedMilliseconds, res.Length / watch.ElapsedMilliseconds));
w.Close();
System.Console.WriteLine(watch.ElapsedMilliseconds);
System.Console.WriteLine(res.Length);
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment