Having a great coverage of unit tests would be a great start, however, it is a bit difficult with Corona, as most of its APIs (Graphics, Audio, etc.) are only available inside the embedded system and I do not want to mock everything.
Snabb (https://github.com/snabbco/snabb) is some tens of KLOC of Lua (LuaJIT) code. This is very hardware-dependent and low-level e.g. network card device drivers and performance sensitive code that is optimized for specific CPU models. Our approach is to run tests in a Continuous Integration lab that has all of the relevant hardware available.
These days our full performance test suite takes around one week of machine time to run and presents statistics on ~50,000 separate benchmark runs. Currently we have around 20 servers in our CI farm to achieve reasonable test throughput for a monthly release cycle.