| OLD | NEW |
| 1 // Copyright 2013 The Chromium Authors. All rights reserved. | 1 // Copyright 2013 The Chromium Authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
| 4 | 4 |
| 5 #include "net/spdy/write_blocked_list.h" | 5 #include "net/spdy/write_blocked_list.h" |
| 6 | 6 |
| 7 #include "testing/gtest/include/gtest/gtest.h" | 7 #include "testing/gtest/include/gtest/gtest.h" |
| 8 | 8 |
| 9 | |
| 10 namespace net { | 9 namespace net { |
| 11 namespace test { | 10 namespace test { |
| 12 namespace { | 11 namespace { |
| 13 | 12 |
| 14 typedef WriteBlockedList<int> IntWriteBlockedList; | 13 typedef WriteBlockedList<int> IntWriteBlockedList; |
| 15 | 14 |
| 16 TEST(WriteBlockedListTest, GetHighestPriority) { | 15 TEST(WriteBlockedListTest, GetHighestPriority) { |
| 17 IntWriteBlockedList list; | 16 IntWriteBlockedList list; |
| 18 EXPECT_FALSE(list.HasWriteBlockedStreams()); | 17 EXPECT_FALSE(list.HasWriteBlockedStreams()); |
| 19 list.PushBack(1, 1); | 18 list.PushBack(1, 1); |
| (...skipping 46 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 66 EXPECT_EQ(1, list.PopFront(4)); | 65 EXPECT_EQ(1, list.PopFront(4)); |
| 67 EXPECT_EQ(2, list.PopFront(4)); | 66 EXPECT_EQ(2, list.PopFront(4)); |
| 68 EXPECT_EQ(1, list.PopFront(4)); | 67 EXPECT_EQ(1, list.PopFront(4)); |
| 69 EXPECT_EQ(1u, list.NumBlockedStreams()); | 68 EXPECT_EQ(1u, list.NumBlockedStreams()); |
| 70 EXPECT_EQ(3, list.PopFront(4)); | 69 EXPECT_EQ(3, list.PopFront(4)); |
| 71 } | 70 } |
| 72 | 71 |
| 73 } // namespace | 72 } // namespace |
| 74 } // namespace test | 73 } // namespace test |
| 75 } // namespace net | 74 } // namespace net |
| OLD | NEW |