OLD | NEW |
1 // Copyright 2014 The Chromium Authors. All rights reserved. | 1 // Copyright 2014 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 <string> | 5 #include <string> |
6 #include <vector> | 6 #include <vector> |
7 | 7 |
8 #include "base/at_exit.h" | 8 #include "base/at_exit.h" |
9 #include "base/auto_reset.h" | 9 #include "base/auto_reset.h" |
10 #include "base/bind.h" | 10 #include "base/bind.h" |
(...skipping 509 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
520 DISALLOW_COPY_AND_ASSIGN(ViewManagerTest); | 520 DISALLOW_COPY_AND_ASSIGN(ViewManagerTest); |
521 }; | 521 }; |
522 | 522 |
523 TEST_F(ViewManagerTest, SecondEmbedRoot) { | 523 TEST_F(ViewManagerTest, SecondEmbedRoot) { |
524 ASSERT_TRUE(EmbedRoot(view_manager_init_.get(), kTestServiceURL)); | 524 ASSERT_TRUE(EmbedRoot(view_manager_init_.get(), kTestServiceURL)); |
525 connection_->DoRunLoopUntilChangesCount(1); | 525 connection_->DoRunLoopUntilChangesCount(1); |
526 EXPECT_EQ(kTestServiceURL, connection_->changes()[0].embed_url); | 526 EXPECT_EQ(kTestServiceURL, connection_->changes()[0].embed_url); |
527 } | 527 } |
528 | 528 |
529 // Verifies client gets a valid id. | 529 // Verifies client gets a valid id. |
530 TEST_F(ViewManagerTest, ValidId) { | 530 #if defined(OS_LINUX) |
| 531 // http://crbug.com/396492 |
| 532 #define MAYBE_ValidId DISABLED_ValidId |
| 533 #else |
| 534 #define MAYBE_ValidId ValidId |
| 535 #endif |
| 536 TEST_F(ViewManagerTest, MAYBE_ValidId) { |
531 // TODO(beng): this should really have the URL of the application that | 537 // TODO(beng): this should really have the URL of the application that |
532 // connected to ViewManagerInit. | 538 // connected to ViewManagerInit. |
533 EXPECT_EQ("OnConnectionEstablished creator=", | 539 EXPECT_EQ("OnConnectionEstablished creator=", |
534 ChangesToDescription1(connection_->changes())[0]); | 540 ChangesToDescription1(connection_->changes())[0]); |
535 | 541 |
536 // All these tests assume 1 for the client id. The only real assertion here is | 542 // All these tests assume 1 for the client id. The only real assertion here is |
537 // the client id is not zero, but adding this as rest of code here assumes 1. | 543 // the client id is not zero, but adding this as rest of code here assumes 1. |
538 EXPECT_EQ(1, connection_->changes()[0].connection_id); | 544 EXPECT_EQ(1, connection_->changes()[0].connection_id); |
539 } | 545 } |
540 | 546 |
(...skipping 853 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1394 // originating connection. | 1400 // originating connection. |
1395 | 1401 |
1396 // TODO(beng): Add tests for focus: | 1402 // TODO(beng): Add tests for focus: |
1397 // - focus between two nodes known to a connection | 1403 // - focus between two nodes known to a connection |
1398 // - focus between nodes unknown to one of the connections. | 1404 // - focus between nodes unknown to one of the connections. |
1399 // - focus between nodes unknown to either connection. | 1405 // - focus between nodes unknown to either connection. |
1400 | 1406 |
1401 } // namespace service | 1407 } // namespace service |
1402 } // namespace view_manager | 1408 } // namespace view_manager |
1403 } // namespace mojo | 1409 } // namespace mojo |
OLD | NEW |