during redmine test with redmine_drawio plugin installed I recognized a failing redmine test since redmine_drawio creates by
default an api key for the current user even if the api is disabled. This will happen in RedmineDrawio::ViewLayoutsBaseHtmlHeadHook when providing the hash code.
In order to fix that redmine test failure I created this pull request which provides the api key only if the api is enabled. Furthermore, it will render a warning for the administrator if the api is not enabled.
And of course, I added some tests. :)
Please let me know if there could be done something better.
Best Regards,
liaham
Update: In contrast to the first PR I fixed a wrong api check and added further tests.
Hi @mikitex70,
during redmine test with redmine_drawio plugin installed I recognized a failing redmine test since redmine_drawio creates by default an api key for the current user even if the api is disabled. This will happen in RedmineDrawio::ViewLayoutsBaseHtmlHeadHook when providing the hash code.
In order to fix that redmine test failure I created this pull request which provides the api key only if the api is enabled. Furthermore, it will render a warning for the administrator if the api is not enabled.
And of course, I added some tests. :)
Please let me know if there could be done something better.
Best Regards, liaham
Update: In contrast to the first PR I fixed a wrong api check and added further tests.