Quantcast Automated Testing - WoWInterface
Thread Tools Display Modes
08-10-19, 06:14 AM   #1
yess
A Fallenroot Satyr
AddOn Author - Click to view addons
Join Date: May 2008
Posts: 21
Automated Testing

Has anyone done some automated tests for their addons?
  Reply With Quote
09-02-19, 12:56 PM   #2
Nikita S. Doroshenko
A Cyclonian
 
Nikita S. Doroshenko's Avatar
AddOn Author - Click to view addons
Join Date: Sep 2015
Posts: 43
I usually just use printings in chat, different values if I set custom debug value to true. Itís not AT, but works fine for me.
  Reply With Quote
09-02-19, 02:04 PM   #3
SDPhantom
A Pyroguard Emberseer
 
SDPhantom's Avatar
AddOn Author - Click to view addons
Join Date: Jul 2006
Posts: 1,847
There really isn't a reliable way for automated testing. For syntax errors, you could run it in a standard Lua interpreter and if it complains about something being nil, then it passed the compile phase and your syntax is correct.

I usually drycode an entire addon, or as much as I can to reach a functional stage. This is to make sure all the files I create are in place by the time I launch the game. WoW only checks for new files when it launches. You should also be pretty solid about your ToC setup as well. Reloading the ToC requires a full login from the account. If you use the BNet desktop client, you might as well close out and relaunch WoW to have it automatically log back in to your account. When you log into a character, you can start your testing. For the most part, you can still edit code while the game is running and apply it using /reload. Keep in mind, if you add a new file and/or change the ToC, you need to close out and relaunch the game.

For testing temporary code, I have a custom development environment addon I made that (among other things) loads in a usually blank Lua file. Any time the game is running, I can write code into this blank file and use /reload to test it. When I'm done, I clear out the file and /reload again to clear it from the game. I do this most of the time with code I post here in the forums before submitting it.
__________________
ESOUI AddOns | WoWInterface AddOns
"All I want is a pretty girl, a decent meal, and the right to shoot lightning at fools."
-Anders (Dragon Age: Origins - Awakening)

Last edited by SDPhantom : 09-02-19 at 02:11 PM.
  Reply With Quote

WoWInterface » Developer Discussions » General Authoring Discussion » Automated Testing

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off