This repository contains an example project designed to demonstrate how to write and run automated tests using AltTester® in a Unity project that utilizes UI Toolkit.
The example includes pre-written tests to showcase how AltTester® can be used to interact with Unity UI elements and validate behaviors. To run these tests, you need to prepare a standalone build of the example project and have AltTester® Desktop running.
- Unity Editor: Install the Unity Editor. Version compatibility depends on the example project.
- AltTester®: Download AltTester® from the provided link.
- .NET SDK: Ensure you have the .NET SDK installed to run the tests (
dotnet test
).
Follow these steps to get started:
- Open Unity Hub and create a new Unity project using your preferred template.
- Download the example project from Example Project Link and import it into your Unity project.
- Download AltTester® from AltTester® Download Link.
- Follow the setup instructions in the AltTester® Documentation.
- Build the project following the instructions in the AltTester® Documentation.
Once the setup is complete, follow these steps to run the tests:
- Open the standalone build (DragonCrasher).
- Launch AltTester® Desktop.
- Navigate to the
Tests
folder in this repository using a terminal or command prompt. - Run the following command:
dotnet test
The tests will connect to the running game and execute automatically.
If you encounter any issues, consult the AltTester® Documentation or reach out to the Discord channel.
Happy Testing! 🚀