In a built application, we want the application to check whether an arbitrary package has been built (composer install
) into the code base.
We were originally thinking of storing a list of all installed packages (including their replace links) and that works for our test cases, but I can image it won't work for chained replacements, for instance: the requirements for package A are checked. A depends on D. The application already has B installed, which replaces C, which replaced D. As such, D is available within the system and A can be installed, but our code currently does not correctly output this, as it only stores B's replaced packages, which is C. It doesn't store C's replaced packages (D). We also need to perform this check programmatically, so there is no CLI environment. The reason we need this, is that the application allows extensions to be enabled runtime (so after the code base has been built), but it must make sure the code base has indeed been built correctly. Those extensions are also their