momi-foundation-coding / nodejs-api-cli

This is a scaffold for generating new API-based application for NodeJS and its frameworks such as Express, kemboijs, koa, AdonisJs etc.
http://www.kemboijs.org/
MIT License
10 stars 13 forks source link

Improve folder structure for tests -> all tests in one file #60

Closed ezkemboi closed 4 years ago

ezkemboi commented 4 years ago
its-tayo commented 4 years ago

Hi @ezkemboi can I have a go at this please?

ezkemboi commented 4 years ago

Sure, thanks and welcome. Go ahead and rais a PR.

ezkemboi commented 4 years ago

Assigned to you @its-tayo.

its-tayo commented 4 years ago

Hi @ezkemboi, can you please let me know what the new test directory structure should look like?

ezkemboi commented 4 years ago

Something like

    tests 
        - controllers
              - user.js
        - middleware
             - middleware.js
        - routes
             - routes.js

It might not be good the first time, but the idea is to have different files/folders for different parts that are testable. Something like models might be tested easily when controllers and other items have been tested. We just want to get rid of the test file being a single file.

In case of any clarification you need or help with the codebase, do let me know. Looking forward to your PR.

ezkemboi commented 4 years ago

@its-tayo we can schedule a call if you need assistance with any part of the codebase or any assistance whatsoever.

its-tayo commented 4 years ago

Alright, thanks. I went through the codebase thoroughly yesterday, hence the delay. Submitting my pr in a bit. But we could still schedule a call though.

ezkemboi commented 4 years ago

@its-tayo thanks for your efforts. I do really appreciate and welcome to the team. Probably about the call, I will send you an email on the same.

its-tayo commented 4 years ago

You're welcome. Looking forward to our call.