ComponentLoader: Add tests, fix loading from package.json