aws-samples / aws-ambit-scenario-designer-ue4

AWS Ambit Scenario Designer for Unreal Engine 4 (Ambit) is a suite of tools to streamline content creation at scale for autonomous vehicle and robotics simulation applications.
https://aws-samples.github.io/aws-ambit-scenario-designer-ue4/
Apache License 2.0
85 stars 21 forks source link

Implement new mock class structure for existing unit tests #21

Closed rukekre closed 2 years ago

rukekre commented 2 years ago

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

Previous implementation of certain unit tests relied on using C++ Lambda's for mocking function calls.

What was the solution? (How)

A new structure has been introduced using an interface to an implementation class and a mock class.

What artifacts are related to this change?

Issues: V508905271

What is the impact of this change?

Improves the structure of the mock classes by implementing a straightforward, simple approach to mocking rather than relying on C++ Lambda's to swap out functions with their mocked versions during testing.

Are you adding any new dependencies to the system?

No.

How were these changes tested?

Tested locally using the Automation testing provided in Unreal Engine. Also tested glTF export (since that has been impacted the most)

How does this commit make you feel? (Optional, but encouraged)

:)


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