2
0
mirror of https://github.com/inventree/InvenTree.git synced 2025-06-18 21:15:41 +00:00

Improve plugin testing (#3517)

* refactor entrypoint into helpers

* Add lookup by metadata
This is geared towards plugins packaged in pkgs that differ in name from their top module

* Make module lookup predictable in changing pkg-envs

* remove no coverage from plugin packages

* ignore coverage for production loadin

* refactor plugin collection - move assigment out

* do not cover fs errors

* test custom dir loading

* test module meta fetcher

* add a bit more safety

* do not cover sanity checkers

* add folder loading test

* ignore again for cleaner diffs for now

* ignore safety catch

* rename test

* Add test for package installs

* fix docstring name

* depreciate test for now

* Fix for out of BASE_DIR paths

* ignore catch

* remove unneeded complexity

* add testing for outside folders

* more docstrings and simpler methods

* make call simpler
This commit is contained in:
Matthias Mair
2022-08-16 05:09:48 +02:00
committed by GitHub
parent 858d48afe7
commit 188ddc3be3
7 changed files with 130 additions and 20 deletions

View File

@ -43,7 +43,7 @@ class PluginAppConfig(AppConfig):
pass
# get plugins and init them
registry.collect_plugins()
registry.plugin_modules = registry.collect_plugins()
registry.load_plugins()
# drop out of maintenance