aws-samples / aws-tools-for-babylonjs-editor

AWS Tools for Babylon.JS Editor is a suite of tools meant to interact with Babylon.JS Editor by utilizing the capabilities of AWS products.
Apache License 2.0
32 stars 9 forks source link

Unit testing for AWS SDK Amplify call #3

Closed eherozhao closed 2 years ago

eherozhao commented 2 years ago

What was the problem/requirement? (What/Why)

Current plugin doesn't have testing covering the AWS SDK calls.

What was the solution? (How)

Added unit testing for AWS Amplify SDK calls by Jest testing framework. By using aws-sdk-client-mock, we can mock the AWS SDK for JavaScript v3.

What is the impact of this change? (Focus on the customer experience)

Provided more robust code for customers to use.

Are you adding any new dependencies to the system?

aws-sdk-client-mock follows MIT license. jest follows MIT license.

How were these changes tested?

  1. Manual testing the Plugin functionalities in BabylonJS Editor.
  2. Passed all unit tests.

By submitting this pull request, I confirm that you can use, modify, copy, and redistribute this contribution, under the terms of your choice.