Lines Matching refs:comp2
52 // "comp2": [
85 manager->AddComponentArrayItem("comp1", "comp2", {"t2"}, nullptr));
87 manager->AddComponentArrayItem("comp1", "comp2", {"t3"}, nullptr));
89 manager->AddComponent("comp1.comp2[1]", "comp3", {"t4"}, nullptr));
90 EXPECT_TRUE(manager->AddComponent("comp1.comp2[1].comp3", "comp4",
447 EXPECT_TRUE(manager_.AddComponent("", "comp2", {"trait3"}, nullptr));
452 "comp2": {
464 EXPECT_TRUE(manager_.AddComponent("comp1", "comp2", {}, nullptr));
466 EXPECT_TRUE(manager_.AddComponent("comp1.comp2", "comp4", {}, nullptr));
471 "comp2": {
495 manager_.AddComponentArrayItem("comp1", "comp2", {"foo"}, nullptr));
497 manager_.AddComponentArrayItem("comp1", "comp2", {"bar"}, nullptr));
498 EXPECT_TRUE(manager_.AddComponent("comp1.comp2[1]", "comp3", {}, nullptr));
500 manager_.AddComponent("comp1.comp2[1].comp3", "comp4", {}, nullptr));
505 "comp2": [
531 EXPECT_TRUE(manager_.RemoveComponent("comp1.comp2[1].comp3", "comp4",
537 "comp2": [
555 EXPECT_TRUE(manager_.RemoveComponentArrayItem("comp1", "comp2", 1, nullptr));
560 "comp2": [
574 EXPECT_TRUE(manager_.AddComponent("comp1", "comp2", {}, nullptr));
575 EXPECT_FALSE(manager_.AddComponent("comp1", "comp2", {}, nullptr));
579 EXPECT_FALSE(manager_.AddComponent("comp1", "comp2", {}, nullptr));
592 EXPECT_TRUE(manager_.AddComponent("comp1", "comp2", {}, nullptr));
594 EXPECT_TRUE(manager_.AddComponent("comp1.comp2", "comp4", {}, nullptr));
615 comp = manager_.FindComponent("comp1.comp2[0]", nullptr);
619 comp = manager_.FindComponent("comp1.comp2[1]", nullptr);
623 comp = manager_.FindComponent("comp1.comp2[1].comp3", nullptr);
627 comp = manager_.FindComponent("comp1.comp2[1].comp3.comp4", nullptr);
632 comp = manager_.FindComponent(" comp1 . comp2 [ \t 1 ] . comp3.comp4 ",
640 // 'comp2' doesn't exist:
641 EXPECT_EQ(nullptr, manager_.FindComponent("comp2", nullptr));
642 // 'comp1.comp2' is an array, not a component:
643 EXPECT_EQ(nullptr, manager_.FindComponent("comp1.comp2", nullptr));
644 // 'comp1.comp2[3]' doesn't exist:
645 EXPECT_EQ(nullptr, manager_.FindComponent("comp1.comp2[3]", nullptr));
647 EXPECT_EQ(nullptr, manager_.FindComponent(".comp2[1]", nullptr));
650 EXPECT_EQ(nullptr, manager_.FindComponent("comp1.comp2[s]", nullptr));
651 EXPECT_EQ(nullptr, manager_.FindComponent("comp1.comp2[-2]", nullptr));
652 EXPECT_EQ(nullptr, manager_.FindComponent("comp1.comp2[1e1]", nullptr));
653 EXPECT_EQ(nullptr, manager_.FindComponent("comp1.comp2[1", nullptr));
680 ASSERT_TRUE(manager_.AddComponent("", "comp2", {"trait2"}, nullptr));
745 EXPECT_EQ("comp2", command_instance->GetComponent());
805 manager_.AddComponent("", "comp2", {"trait1", "trait2"}, nullptr));
816 manager_.AddCommandHandler("comp2", "trait1.command1",
818 manager_.AddCommandHandler("comp2", "trait2.command2",
836 "component": "comp2"
848 "component": "comp2",
919 "comp2": [
951 "comp2": [
976 ASSERT_TRUE(manager_.SetStateProperties("comp1.comp2[1].comp3.comp4", *state3,
984 "comp2": [
1013 "comp1.comp2[1].comp3.comp4",
1020 "comp2": [
1108 EXPECT_EQ(nullptr, manager_.GetStateProperty("comp2", "trait.prop", nullptr));
1146 ASSERT_FALSE(manager_.SetStateProperty("comp2", "trait1.prop2", p1, nullptr));
1172 manager_.AddComponent("", "comp2", {"trait1", "trait2"}, nullptr));
1191 ASSERT_TRUE(manager_.SetStateProperty("comp2", "trait2.prop3", foo, nullptr));
1207 ASSERT_TRUE(manager_.SetStateProperty("comp2", "trait2.prop3", bar, nullptr));
1219 EXPECT_EQ("comp2", snapshot.state_changes[1].component);
1229 EXPECT_EQ("comp2", snapshot.state_changes[3].component);
1257 ASSERT_TRUE(manager_.AddComponent("", "comp2", {"trait3"}, nullptr));
1261 EXPECT_EQ("comp2", manager_.FindComponentWithTrait("trait3"));
1462 ASSERT_TRUE(manager_.AddComponent("", "comp2", {"trait2"}, nullptr));
1467 "comp2", R"({"trait2": {"prop3": "baz", "prop4": "quux"}})", nullptr));