DSGT-DLP / Deep-Learning-Playground

Web Application where people new to Deep Learning can input a dataset and toy around with basic Pytorch modules without writing any code
MIT License
26 stars 8 forks source link

[FEATURE]: Write Tests for serverless lambdas #916

Open dwu359 opened 1 year ago

dwu359 commented 1 year ago

Feature Name

Write Tests for serverless lambdas

Your Name

Daniel Wu

Description

This issue is best started once #914 is complete.

Write tests to test the serverless lambda endpoints created through SST, one for trainspaces and another for user-uploaded datasets. For each test, use existing endpoints to implement in this order:

It is best to use vitest as the testing framework for this, since that is the one that is most supported with SST.

github-actions[bot] commented 1 year ago

Hello @dwu359! Thank you for submitting the Feature Request Form. We appreciate your contribution. :wave:

We will look into it and provide a response as soon as possible.

To work on this feature request, you can follow these branch setup instructions:

  1. Checkout the main branch:

     git checkout nextjs
  2. Pull the latest changes from the remote main branch:

     git pull origin nextjs
  3. Create a new branch specific to this feature request using the issue number:

     git checkout -b feature-916

    Feel free to make the necessary changes in this branch and submit a pull request when you're ready.

    Best regards, Deep Learning Playground (DLP) Team

karkir0003 commented 1 year ago

@dwu359 does vitest do mocking under the hood or it actually makes the server calls for real?

karkir0003 commented 1 year ago

example usage of vitest in sst: https://sst.dev/chapters/unit-tests-in-serverless.html