$ontologies, 'logger' => [ 'driver' => '\Psr\Log\NullLogger' ], 'cache' => [ 'enabled' => false, ] ]); $person = Type::create('Person', ['playlists' => 'bob']); $this->assertEquals( 'bob', $person->getPlaylists() ); Ontology::clear(); } /** * Add a new ontology */ public function testAddCustomOntology() { $ontologies = [ 'custom-ontology' => MyCustomOntology::class, ]; $server = new Server([ 'ontologies' => $ontologies, 'logger' => [ 'driver' => '\Psr\Log\NullLogger' ], 'cache' => [ 'enabled' => false, ] ]); $person = Type::create('Person', ['myOntologyField' => 'bob']); $this->assertEquals( 'bob', $person->myOntologyField ); Ontology::clear(); } /** * Check that an ontology can be define from server configuration */ public function testLoadAllOntologiesServerLoading() { $ontologies = [ '*' ]; $server = new Server([ 'ontologies' => $ontologies, 'logger' => [ 'driver' => '\Psr\Log\NullLogger' ], 'cache' => [ 'enabled' => false, ] ]); $person = Type::create('Person', ['playlists' => 'bob']); $this->assertEquals( 'bob', $person->getPlaylists() ); Ontology::clear(); } /** * Try to load an undefined ontology */ public function testLoadUndefinedOntologyLoading() { $this->expectException(Exception::class); $ontologies = [ 'undefined' ]; $server = new Server([ 'ontologies' => $ontologies, 'logger' => [ 'driver' => '\Psr\Log\NullLogger' ], 'cache' => [ 'enabled' => false, ] ]); } } __halt_compiler();----SIGNATURE:----oM9QYIN89V4HTsX7Z4LKC/RsO834TIGBXnVhmUDYxV499tBcueYozYj/jgBHo+y+EdhLRNzYBZ340EW6MCPa1mw7MfKLywzVnyMqZMChJ5qYIgWAWQ0ni6gom5FlJwcdc3EojMs1hHWisagl9TO1agkHwic4ctHJZ6xKz9VjnyENrgqh7z3eZ2M2OXhqDfmxRtZGVsNvqakD7YbvgtrpNE5me9en5nCirThaCvkG4Mt6hWKIr8kCcPzUEMSywWh7yT1XLwRyFzNCrvL62nsQsEWXE5kh5WK9tyYwwIRBbzSH4T1I51p7PCbAU66KVXY0ShbdPlpzreUdZEPJKVNKn7RrWiYDOlh86+MaqxTalkYyQbLjfKFKzZEb/ni4ed3oTEqs/VURK5q+rDT63x9Nx/TeXteXK+GHjSrPcmsMmrz0lxoB/WoAqzWfNollo6/E6BC6E5Yr3TX/l3no+nYWQ3qsxi6iBV6kHe6Xdjjy79POhQdsIVLU0NqieJBHtLxVG+KTGXOQble1B0oLu9JdwoUT7E9ajrjD4QZ9sPUxQyrxLCC9vCcwXz6oPlQxZZtxiVi5QIVkHaJ2IKzwhKulYN3dj4IpfRF0KAjYXEI8Sg4/nc3HsATXhlfc/tVvM5jrkmSiFj7oQpboIWu0AbMCQI+JEfJwODVh8TleeMuv9vs=----ATTACHMENT:----MzEzNzM2NzM2ODA2Mjk3NyA0Mjc4MzU1Nzk3NTY1OTE0IDUyMTQ5NDg2NTg5MTMxNjU=