$yml, ]); $builder = new ContainerBuilder(); $yaml_file_loader = new YamlFileLoader($builder); $yaml_file_loader->load('vfs://drupal/modules/example/example.yml'); $this->assertEquals(['_provider' => [['provider' => 'example']]], $builder->getDefinition('example_service')->getTags()); $this->assertTrue($builder->getDefinition('example_service')->isPublic()); $this->assertFalse($builder->getDefinition('example_private_service')->isPublic()); $builder->compile(); $this->assertTrue($builder->has('example_service')); $this->assertFalse($builder->has('example_private_service')); } }