Dependency installation adds more dependencies

2

This is the first time I'm trying to work with composer , the purpose is to use only PHPUnit , since I do not use any dependencies anymore. When installing composer , with composer.json having only PHPUnit as a dependency, it still installs other dependencies like:

  • symfony
  • doctrine
  • phpspec
  • sebastian
  • phpdocumentor

I do not know if they are required in composer or if it is 'intrusive' and installs this every time. I've heard of some of these dependencies, but I've never used them and I do not know how to use them. What do each of them do for the project? Is it possible to delete? How?

    
asked by anonymous 26.05.2016 / 16:20

1 answer

2

The package PHPUnit to work needs some other packages (dependencies).

In your package spec are:

Anyquestionsonthe package manager site in the PHPUnit . Some are PHP's own libraries and others are packages such as: symfony / yaml

Just remembering that without these additional packages the main package does not work. There is another factor also to note that these other packages may have their own packages to function as well.!

Note the requires item of the package, the item determines the dependencies of the package.

    
26.05.2016 / 16:32