microsoft / sample-app-aoai-chatGPT

Sample code for a simple web chat experience through Azure OpenAI, including Azure OpenAI On Your Data.
MIT License
1.45k stars 2.16k forks source link

[upgrade] Start Jest test coverage #785

Closed iseabock closed 2 months ago

iseabock commented 2 months ago

Motivation and Context

Frontend should have a test suite to catch regressions and assert understood functionality.

Description

Within the frontend directory one can run npm run test to run current test suite.

More test to come and future integration into build pipeline possibly.

スクリーンショット 2024-04-15 170710

Contribution Checklist

abhahn commented 2 months ago

Thanks for adding this! Could you also add a step to the nodejs workflow to run the tests after the build? If it will be a lot of work, it's okay to also suggest it be a part of a separate PR. LMK what you think.