ufosc / Club_Website_2

UF Open Source Club Website
https://ufosc.org
GNU Affero General Public License v3.0
13 stars 41 forks source link

TEST: /api/edit ROUTE #158

Closed zeim839 closed 1 year ago

zeim839 commented 1 year ago

TODO:

  1. Create test/edit.spec.js file.
  2. Test /api/blog route

For reference, see the testing scripts for /api/users. If you're interested on working on this issue, leave a comment and I'll respond with the requirements & specifications.

Thinura commented 1 year ago

Hi @zeim839 I would like to contribute to this issue. Could you share more details regarding requirements and specifications?

zeim839 commented 1 year ago

@Thinura

Thanks for volunteering! Keep in mind that this is a time consuming issue, so feel free to complete as many or as few specs as you wish.

The testing file should be created in test/blog.spec.js. For testing, we use MochaJS and ChaiJS. Refer to test/users.spec.js for an example.

Each of the following specifications (demarcated with a '-' prefix) should constitute a separate Mocha test, i.e:

it('Should ...') { /* ... */ }

Refer to README and CONTRIBUTING for instructions on setting up the project and contributing.

Testing specifications:

Route: GET /:id

Route: DELETE /:id

Route: PUT /:id

Route: POST /

Route: GET /