Have framer store frame type currently being processed

This CL has QuicFramer save the frame type for the frame that it currently
is extracting from the packet and processing. This is done so that the
IETF QUIC Transport Connection Close can get the type of frame that
precipitated the close. If the frame-type was not saved like this then
it would need to be passed around in the call stack -- one more parameter
threaded throughout many calls in QUIC.

This done only when IETF Framing (version 99) is enabled.

Tests in quic_framer_test.cc have been modified to check that the right
frame type has been saved (done in all of the On...Frame upcalls, so that
the testing is fairly complete). Also checks that the saved type is 0
when not processing a frame (eg, when doing header processing) OR when not
doing IETF QUIC Framing.

gfe-relnote: N/A is only for Version 99/IETF QUIC Framing.
PiperOrigin-RevId: 265888094
Change-Id: If068d49c9f72b4e3c0e8eb3e7ab7460abde85f8a
diff --git a/quic/core/http/end_to_end_test.cc b/quic/core/http/end_to_end_test.cc
index c3d645d..9aab379 100644
--- a/quic/core/http/end_to_end_test.cc
+++ b/quic/core/http/end_to_end_test.cc
@@ -4138,7 +4138,11 @@
       session, GetNthClientInitiatedBidirectionalId(max_number_of_streams + 1));
   client_->SendCustomSynchronousRequest(headers, body);
   EXPECT_EQ(QUIC_STREAM_CONNECTION_ERROR, client_->stream_error());
-  EXPECT_EQ(QUIC_INVALID_STREAM_ID, client_->connection_error());
+  EXPECT_EQ(QUIC_INVALID_STREAM_ID, GetClientSession()->error());
+  EXPECT_EQ(IETF_QUIC_TRANSPORT_CONNECTION_CLOSE,
+            GetClientSession()->close_type());
+  EXPECT_TRUE(
+      IS_IETF_STREAM_FRAME(GetClientSession()->transport_close_frame_type()));
 }
 
 TEST_P(EndToEndTest, TestMaxPushId) {