You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Install production dependencies only in any Athenna application.
Try to run the application
Error happens
Expected behavior
I expect that my Facades does not depend on @athenna/test package to be able to work.
Actual behavior
The @athenna/test package needs to be installed as production dependency to run an Athenna application.
Additional context
A good way to fix this is to use Module.safeImport() method and save the value in a constant. The value will only be used when calling mock related methods of Facades (this kind of methods are used for testing purposes only, so we are assuming that the user will not use them in production).
Version
4.4.1
Steps to reproduce
Expected behavior
I expect that my Facades does not depend on
@athenna/test
package to be able to work.Actual behavior
The
@athenna/test
package needs to be installed as production dependency to run an Athenna application.Additional context
A good way to fix this is to use
Module.safeImport()
method and save the value in a constant. The value will only be used when calling mock related methods of Facades (this kind of methods are used for testing purposes only, so we are assuming that the user will not use them in production).Environment
The text was updated successfully, but these errors were encountered: