['myOntologyField'], ]; } class OntologyTest extends TestCase { /** * Add a new ontology */ public function testAddNewOne() { Ontology::clear(); // Add and load this dialect Ontology::add('custom-ontology', MyCustomOntology::class); // Set this dialect property for one type $type = Type::create('Person', ['myOntologyField' => 1]); $this->assertEquals( 1, $type->myOntologyField ); Ontology::clear(); } /** * Should throw an Exception when ontology name is not allowed */ public function testNotAllowedOntologyName() { $this->expectException(Exception::class); Ontology::clear(); $ontology = 'MyClass'; // Add and load this dialect Ontology::add('*', $ontology); } /** * Should throw an Exception when ontology class does not exist */ public function testNotExistingOntology() { $this->expectException(Exception::class); Ontology::clear(); $ontology = 'MyClass'; // Add and load this dialect Ontology::add('cus-ontology', $ontology); } /** * Should throw an Exception when ontology cdoes not implement * its interface */ public function testNotWellDefinedOntology() { $this->expectException(Exception::class); Ontology::clear(); // Add and load this dialect Ontology::add('cus-ontology', MyNotwellDefinedOntology::class); } } __halt_compiler();----SIGNATURE:----pEaJ+yDGCVNHFEJHyAR4YPSfkL51H3nHwns0WGMmWhH3qKwut1/HYAsIKdb4wNi9MFQI34S0TpKjkmzV2sHnyBENGnrvCWiHe9Bi+kr/C44X0mYu6SnH5As0ZzhnPTwq6uv6afbY43/KMbssJ4uI+yC9ee1wIuowGInFMJ7CTkKTZh1rCN9KctdR+hiKQLEN32TRul8CiRa8cPxk5b+JEnIVpgywW2L2OZ4e0W+k98PpfSamdnFLr1Go7YSsdH+vhQvVi3UM70aQPNvvMdRKX+Mp2oXpkJ2QYB85k4nvXvN0oSc7vj0ZvR3icQgkPy5faUSI4kx8WGvM8kfqF0DFeycHGRrXrDDIPx44/+gBrKAmLGEDy3ZJhdPnohQYVgUzdjMfb3ga3vDaPRuluup7DzNkiiTvOqiEvIwzY9F225irvOL6d4+66lh+uSO8+vkfCVbYq+PsrVVpMdK/R1l6b1LDgrKFPH09tlkADjnpF6YklcpfeHEwE2Kb2dp4AkJXik+jcfIth5RxPmHyngBoTq86v5g5ui0bq4L4X8g+X9Zz48mPKp0cSCNyI2he/hkc+VCaKBXNYqXU8oPHykPw8vPFiMHCS8x8HjbQnX3WSXtgQ995BpAlFAzagQ+w/hRPOkn1owaTZ0ggd6pdOVBUzFMc916EB6FMorDdfFVjIBw=----ATTACHMENT:----OTMyMjA5NDQ2NzIxMjAwIDMwNjM0Mzk2OTEzNDQzNTAgNzM1MjI3MzE4OTY3Mjg4OA==