zenstackhq / zenstack

Fullstack TypeScript toolkit that enhances Prisma ORM with flexible Authorization layer for RBAC/ABAC/PBAC/ReBAC, offering auto-generated type-safe APIs and frontend hooks.
https://zenstack.dev
MIT License
2.07k stars 88 forks source link

[BUG] Problem with tests #545

Closed chemitaxis closed 1 year ago

chemitaxis commented 1 year ago

Description and expected behavior When I run my tests, now I can't get the DefaultMetaData. The problem is that has been changed how to obtain the model when is running with process.env.NODE_ENV.

https://github.com/zenstackhq/zenstack/commit/2280f83cd7f1f597fddfd6ab0c99417200124452#diff-97e3bb8d674b3d26b0c6f26690850035641138b48cacaa40b7a24de0ddfd1a34R11

Screenshots

Screenshot 2023-07-04 at 13 10 58

Environment (please complete the following information):

Additional context If I use the NODE_ENV = production everything works fine

chemitaxis commented 1 year ago

I know where is the problem... you are missing the default