Question about using gdUnit as an API #96
-
We're building a live editor for Godot which runs in the browser and validates custom user code We have the editor part working (tweet of the early proto), with error reporting and so on, and we're now deciding how to implement validation. Instead of reinventing the wheel, I'm looking at gdUnit and I think I like what I see, but I am not clear if it can fit the bill. I'd have two questions:
|
Beta Was this translation helpful? Give feedback.
Replies: 3 comments 2 replies
-
Hello, thank you for the interest and the look into my project
Generally it should be possible to run inside a browser, the code is 99% pure GdScript (running in a browser I never tested).
GdUnit was not designed as an API for third party systems but it should in principle be possible via a custom executor to run dynamic generated tests. If you have any further questions, please contact me. |
Beta Was this translation helpful? Give feedback.
-
Hello @Xananax any questions? |
Beta Was this translation helpful? Give feedback.
-
Ok, this means in GdUnit terms that you will have a test suite that will test a scene. A test case will test if a player jumps when a custom button is pressed. It is still unclear to me when the tests should be executed. According to your example the tests run independently from the actual scene run or? The code to execute a test suite is very simple.
|
Beta Was this translation helpful? Give feedback.
Ok, this means in GdUnit terms that you will have a test suite that will test a scene. A test case will test if a player jumps when a custom button is pressed.
It is still unclear to me when the tests should be executed. According to your example the tests run independently from the actual scene run or?
So the input is not tested in real time?
Which Godot version do you use for the export?
The code to execute a test suite is very simple.