You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Hi, I am new to Unity so I might be inventing a wheel here.
The idea is to be able to print some variables together with the assertion message, e.g., if an assertion is inside a loop, it would be handy to know the loop iteration when it fails:
Update:Here it was proposed to add __VA_ARGS__ directly to all _MESSAGE macros. That approach is definitely much better than my proposal above. Is anyone working on that? If not, I could try implementing it.
The text was updated successfully, but these errors were encountered:
É uma excelente ideia buscar melhorias na funcionalidade de mensagens de assert no Unity, especialmente para incluir informações de contexto úteis, como o número de iteração de um loop. A proposta de adicionar VA_ARGS diretamente a todas as macros _MESSAGE parece ser uma abordagem mais elegante e eficiente do que a proposta inicial de usar snprintf em uma macro personalizada. Se ninguém está trabalhando nisso atualmente, você certamente poderia tentar implementar essa melhoria. Seria ótimo ver essa funcionalidade aprimorada no Unity.
Hi, I am new to Unity so I might be inventing a wheel here.
The idea is to be able to print some variables together with the assertion message, e.g., if an assertion is inside a loop, it would be handy to know the loop iteration when it fails:
A simplistic implementation is as follows. Of course it assumes that there's only one assertion reported per test.
Update: Here it was proposed to add
__VA_ARGS__
directly to all_MESSAGE
macros. That approach is definitely much better than my proposal above. Is anyone working on that? If not, I could try implementing it.The text was updated successfully, but these errors were encountered: