![]() ![]() Bower's ability to install the same files to the same place and provide an explicit mechanism for reconciling which file gets written is a strength, but the dependency hell this process can engender is a worrisome weakness. In addition, I have written tests that depend on multiple versions of dependencies (I wrote a thing that ran a complex test suite against every published version of node-mongodb, which was an interesting experience I will, with luck, never be asked to repeat), so I know this isn't the only way to solve that particular problem.īringing Bower into the discussion is an interesting wrinkle, because it makes me wonder what impacts a change like this might have on the front end, both good and bad. I have a hard time believing that it would be possible to constrain a solution to this problem in such a way that it wouldn't be subject to the same complications that was so wary of in #2943 and #798. Perhaps this feature request is a tiny bit more viable than #2943? A single-line module express3 that depends on and exports it solves all my problems. The best workaround is, unfortunately, abusing the npm database. Obviously, I have code that conditionally applies to one or another version, and no code coverage tool understands that, if I need to run npm test twice (or more times). In addition, this wrecks any chance of receiving proper code coverage reports. I could use npm install & npm test & npm install & npm test, but that is very significantly slower than running my entire test suite. The tests become more of integration tests as opposed to unit tests, but that only makes them more useful. ![]() I could fake both versions of Express, but I consider that using a real Express app is a better deal. In my use case I have a library ( frozen-express) that can during runtime take an object produced by another library (Express app) and do useful things with it.ĭuring development I want to be able to test my application with different versions of my dependency. This is a subset of aliasing features that were rejected in #2943. I have a need to install multiple versions of a dependency at once. Currently a package can have only a single version of a dependency defined. ![]()
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |