I'm working on a project that's a WordPress plugin. This is my directory structure:
├── src/
│ ├── plugin-name.php
│ └── readme.txt
├── tests/
└── ...
I want to include a composer.json file with the plugin so that users can install with Composer if they wish. For example:
├── src/
│ ├── composer.json
│ ├── plugin-name.php
│ └── readme.txt
├── tests/
└── ...
But I also want to use the vfsStream
component when I'm unit testing the plugin. This will mean I'll need to require vfsStream
in a composer.json file that's in my root. For example:
├── src/
│ ├── composer.json
│ ├── plugin-name.php
│ └── readme.txt
├── tests/
├── composer.json
└── ...
I'm not sure a single project can have 2 composer.json files. Is having 2 composer.json files the right way to go about this?