netzo / fresh-netzo

Full-stack Deno Fresh meta-framework for building business web apps like internal tools, dashboards, admin panels and automated workflows.
https://netzo.io
MIT License
51 stars 3 forks source link

chore: enable formatting in ci #89

Closed deer closed 9 months ago

deer commented 9 months ago

Let's see if we can get the code to be formatted for starters. I also tried running deno task test, and it couldn't even run. So the change to deno.jsonc prevents the test runner from looking at any of the templates.

The issue is the monorepo problem:

error: Module not found "file:///Users/reed/code/netzo/netzo/islands/accounts/Form.tsx".
    at file:///Users/reed/code/netzo/netzo/templates/crm/routes/accounts/[id].tsx:4:29

Deno doesn't know that this is governed by a separate deno.json file.

After this change the tests at least run locally, but most of them fail.

miguelrk commented 9 months ago

Great! Was already getting tired of manually having to format every once in a while 😆 ... regarding the testing story, it might be best to remove tests under netzo/integrations/apis (except those for the base constructor at netzo/integrations/create-client, since credentials are usually required for each, and many are under a paywall so it's inviable. That being said, we could also set up msw which I've been meaning to do, but I still thinks testing each client (which underlyingly uses the same createClient) is dupplicating efforts and/or testing the actual APIs which is out of scope.

What do you think? I'd much rather have more thorough testing for createClient as well as the underlying auth and universal pagination adapters under netzo/integrations/create-client/.

Merging this...