Commit Graph

1813 Commits

Author SHA1 Message Date
Lucas Clemente
8ec11c0b53 Move testdata/ to internal/ 2017-08-18 12:06:36 +02:00
Lucas Clemente
d0fde2b230 Merge pull request #788 from glutamatt/fix-type
Fix typo
2017-08-13 11:49:52 +02:00
glutamatt
baa6005b9c Fix type 2017-08-13 00:52:44 +02:00
Marten Seemann
f3b8678ca6 Merge pull request #784 from lucas-clemente/quic38
add support for QUIC 38
2017-08-11 00:19:05 +07:00
Marten Seemann
71ff144c20 add QUIC 38 to supported versions 2017-08-10 20:26:36 +07:00
Marten Seemann
be338c8389 send a Public Reset when receiving the NSTP tag in the CHLO
We currently don't support the no STOP_WAITING experiment.
2017-08-10 20:26:31 +07:00
Marten Seemann
f6e8ce5c67 make tests independent of the supported QUIC versions
Now it's no longer necessary to edit the h2quic tests when adding a new
QUIC version to the slice of supported versions.
2017-08-10 20:23:20 +07:00
Marten Seemann
01baba83a5 don't pass the STOP_WAITING to the receivedPacketHandler
Only pass the LeastUnacked. This makes easier to remove STOP_WAITINGs
later.
2017-08-10 20:23:10 +07:00
Lucas Clemente
e42790eb20 Merge pull request #785 from lucas-clemente/go1.9rc2
Use 1.9rc2 on travis
2017-08-10 12:36:11 +02:00
Lucas Clemente
5bf3b710c0 Use 1.9rc2 on travis 2017-08-10 11:06:38 +02:00
Marten Seemann
698c8ceee8 reject STOP_WAITING frames that have a least unacked of 0 2017-08-10 09:33:14 +07:00
Marten Seemann
18c2ed33d3 Merge pull request #783 from lucas-clemente/better_reads
use io.ReadFull instead of Read to read into known length slices
2017-08-07 13:54:22 +07:00
Marten Seemann
f535cc40de use io.ReadFull instead of Read to read into known length slices 2017-08-04 19:36:24 +07:00
Marten Seemann
2b04d25a55 Merge pull request #777 from lucas-clemente/use-slice-sort
use sort.Slice to sort the tags in the handshake message
2017-08-02 15:09:45 +07:00
Marten Seemann
bf094c9dbb Merge pull request #774 from lucas-clemente/contexts
implement a context for streams and for the session
2017-08-02 12:02:28 +07:00
Marten Seemann
beadeb9da7 use sort.Slice to sort the tags in the handshake message
sort.Slice was added in Go 1.8. Now that we've dropped support for Go
1.7, we can make use of it.
2017-08-02 12:00:52 +07:00
Marten Seemann
8ef69143ba implement a context for the stream
The context is cancelled when the write-side of the stream is closed.
2017-08-02 11:28:17 +07:00
Marten Seemann
e02f5d5fbe replace Session.WaitUntilClosed() by a context 2017-08-02 11:27:44 +07:00
Marten Seemann
811315e31a Merge pull request #773 from lucas-clemente/fix-772
return an error when Write is called on a closed stream
2017-07-29 07:10:52 +07:00
Marten Seemann
77d4573d9b return an error when Write is called on a closed stream 2017-07-29 00:19:39 +07:00
Marten Seemann
3e012f77c8 Merge pull request #742 from lucas-clemente/streamtest-deadlines
use the new gbytes.TimeoutReader and TimeoutWriter in the stream tests
2017-07-26 16:45:02 +07:00
Marten Seemann
315aa14ab5 use the new gbytes.TimeoutReader and TimeoutWriter in the stream tests
This makes sure that our tests fail, even if stream.Read or stream.Write
block.
2017-07-26 16:15:48 +07:00
Marten Seemann
d4fb1c3402 Merge pull request #766 from lucas-clemente/benchmarks
move benchmarks to separate package, speed up CI builds
2017-07-26 16:13:54 +07:00
Marten Seemann
bc1858c7ec speed up the CI builds by using the new benchmark test flags
Reduce the number of samples and the amount of data transferred.
2017-07-26 16:00:41 +07:00
Marten Seemann
30bcc48e52 read file size and number of samples for benchmark test from flags
The values default to what we used previously.
2017-07-25 15:19:01 +07:00
Marten Seemann
d108e10420 move benchmark test to a separate package 2017-07-25 15:17:32 +07:00
Marten Seemann
2c2ca2e670 Merge pull request #764 from lucas-clemente/fix-761
speed up the benchmark test by fetching random data only once
2017-07-25 15:16:21 +07:00
Marten Seemann
4b63b09d0f Merge pull request #768 from lucas-clemente/fix-767
fix some race conditions in client tests
2017-07-25 14:59:16 +07:00
Marten Seemann
a555e3be82 Merge pull request #756 from lucas-clemente/fix-755
fix flaky benchmark test on CIs
2017-07-25 14:58:55 +07:00
Marten Seemann
4c73b935f5 fix some race conditions in client tests 2017-07-25 13:30:49 +07:00
Marten Seemann
b11d77e0df speed up the benchmark test by fetching random data only once
Reading from math.rand takes a long time when running the benchmark
with the race detector. By transferring the same data in every test, we
only have to do that once.
2017-07-25 11:42:01 +07:00
Marten Seemann
ce2333acd6 fix flaky benchmark test on CIs
The server now waits until the client has completed the handshake. This
way, we should avoid sending too many undecryptable packets.
2017-07-25 08:39:32 +07:00
Marten Seemann
43279c37a8 Merge pull request #753 from lucas-clemente/fix-734
implement a h2quic.RoundTripOpt that allow to only use cached QUIC conns
2017-07-25 08:36:51 +07:00
Marten Seemann
ab2bee4002 Merge pull request #749 from lucas-clemente/fix-741
implement net.Error interface for stream deadline expiration errors
2017-07-24 23:14:30 +07:00
Marten Seemann
8ccadf2088 Merge pull request #758 from lucas-clemente/fix-757
Revert "use a finalizer to close the h2quic.RoundTripper"
2017-07-24 23:04:23 +07:00
Marten Seemann
89e88ac6a0 Merge pull request #754 from lucas-clemente/fix-641
fix a race condition in a session test
2017-07-24 22:48:18 +07:00
Marten Seemann
6bd6594003 implement a h2quic.RoundTripOpt that allow to only use cached QUIC conns 2017-07-24 21:46:18 +07:00
Marten Seemann
6546e13e26 implement net.Error interface for stream deadline expiration errors 2017-07-24 21:45:07 +07:00
Marten Seemann
36ee4bd36b Revert "use a finalizer to close the h2quic.RoundTripper"
This reverts commit 65cea185bd.

The finalizer may run even before the h2quic.RoundTripper
variable falls out of scope. This can result in closing
the session before a HTTP transfer has completed.
2017-07-24 21:43:52 +07:00
Marten Seemann
f43e732e4b fix a race condition in a session test
We were relying on the run-loop to set handshakeComplete to true, while
at the same time sending packets. select doesn't guarantee the order of
execution when multiple cases can run. The fix is setting
handshakeComplete to true directly.
2017-07-24 21:42:05 +07:00
Marten Seemann
1060582a18 Merge pull request #760 from lucas-clemente/fix-759
use the gbytes.TimeoutReader in integration tests
2017-07-24 21:40:23 +07:00
Marten Seemann
1d1edfa615 use the gbytes.TimeoutReader in integration tests 2017-07-24 19:22:09 +07:00
Lucas Clemente
e45a89b55c Merge pull request #744 from Injust/master
Removal of Alternate-Protocol header
2017-07-17 19:38:19 -07:00
Justin
0c3a466805 Remove Alternate-Protocol header 2017-07-17 22:20:40 -04:00
Justin
33bb42488a Remove Alternate-Protocol header 2017-07-17 22:20:34 -04:00
Marten Seemann
61f558a2b6 Merge pull request #579 from lucas-clemente/stream-deadlines
implement stream deadlines
2017-07-16 12:08:24 +07:00
Marten Seemann
56155986e9 read the CI timescale factor from an environment variable 2017-07-15 23:51:24 +07:00
Marten Seemann
cfc7d1604d scale all deadline duration in stream tests on the CIs by 20
This allows us to run the tests faster locally. On the CIs, where the
timing is less accurate, the tests take longer, but won't be flaky.
2017-07-15 23:46:15 +07:00
Marten Seemann
e09993403d add stream deadlines to the Stream interface 2017-07-15 23:46:15 +07:00
Marten Seemann
1acdc5f18e implement write deadlines 2017-07-15 23:46:15 +07:00