Automated Testing
I was curious if anyone had found a good automation testing framework for Noesis GUI's that is independent of windows?
Re: Automated Testing
We already have an internal tool here for testing the quality of builds, we render hundreds of XAMLs and compare pixel by pixel with reference images. Adding support for input should be easy. Noesis already provides you a platform independent input system through View functions.
If anyone is interested in improving this command line tool (with a GUI for example, to record input events, capture reference images, etc) just contact us please.
If anyone is interested in improving this command line tool (with a GUI for example, to record input events, capture reference images, etc) just contact us please.
Re: Automated Testing
We are interested in this as well. Especially an interface like selenium or cypress that lets you:
Find UI elements programmatically by using identifiers and traversing the hierarchy.
Trigger click on those elements.
Assert on UI elements to have specific properties, exist, be visible etc.
If the possibility to do these things exist we could sort of build our own testing framework around it.
Preferably in the same application that runs the engine (would make it easier to debug tests), but that's not a must.
Find UI elements programmatically by using identifiers and traversing the hierarchy.
Trigger click on those elements.
Assert on UI elements to have specific properties, exist, be visible etc.
If the possibility to do these things exist we could sort of build our own testing framework around it.
Preferably in the same application that runs the engine (would make it easier to debug tests), but that's not a must.
Re: Automated Testing
We have developed an automated testing system that runs in Unity's Playmode Tests framework. It's in-house specific to our product so I can't share any code, but I can share the general principle we use.
- Assign a unique ID to UI elements relevant to tests using an Attached Property.
- Elements add their ID to a dictionary when Loaded.
- Tests are executed as a series of commands such as Touch(ID), WaitUntilVisible(ID, Timeout), Assert(ID, ID => bool) using a mix of methods on the elements themselves and methods such as View.TouchUp and View.TouchDown.
- Commands are combined into more and more complex and useful commands in order to make tests easier to write and understand.
- Tests are able to run asynchronously through the use of Unity Coroutines.
- Unity lets you speed up the execution of your entire application, so we can run a lot of tests in a short amount of time.
Re: Automated Testing
Coming from WPF I'd see the main advantage of XAML being able to work with view models/MVVM which seems to work pretty nice with Noesis GUI. That should be the cleanest and most flexible way of unit testing/integration testing.
In the project that I am working at the moment, I use view models for every window/control and do the testing only over the view models - completely without UI/XAML/Noesis GUI. That's especially interesting because I don't even rely on Unity. The unit tests therefore don't run under Unity but in Visual Studio.
In the project that I am working at the moment, I use view models for every window/control and do the testing only over the view models - completely without UI/XAML/Noesis GUI. That's especially interesting because I don't even rely on Unity. The unit tests therefore don't run under Unity but in Visual Studio.
Who is online
Users browsing this forum: Ahrefs [Bot], Google [Bot], Semrush [Bot] and 24 guests