If I stop what I'm up to currently to fabricate tooling for this, I'll be running
multiple gameworlds so that up to
n
slots worth of
open PRs can be available for testing simultaneously. Something along the lines of:
0.) spawn clean chroot
1.) preinstall makedeps
2.) git shallow clone
3.) git checkout new %autonamed% branch,
4.) git pull foreign remote
5.) makepkg PKGBUILD
6.) lease ports and request database from an overseer process
7.) generate config.lua
8.) overwrite /world with custom testing map and inject
9.) launch daemon
10.) make announcement
Permanent testers could have actual accounts that are preserved, where the baseline database snapshot includes them. But one thing I do not want to add to this mix is PHP.
I despise PHP and usually rewrite PHP dependencies of software I want to use in NodeJS and Pug.
The biggest hurdles are definitely:
a.) Creating a suitable purpose built testing environment map
b.) Generating scenarios that adequately interface with the changed components
I believe I have a workable protocol concept for collaboration on such a thing...
OpenTibia collaborative community developer testing platform suite:
- To facilitate multiple community developers providing modules containing unit tests, tooling, and scenarios:
- A collection of these modules consisting of maps and scripts shall be merged:
- Hereafter community developers shall be referenced as comdevs.
- Hereafter the root module and overall project shall be referenced as inquisition.
- I will open a repo, where each comdev who wishes to participate shall:
- Pull-request for the inclusion of their testing module.
- The pull-request shall target these assets into a subfolder.
- That subfolder shall carry their identity with its name:
- Either: The comdevs username on OTLand or The comdevs username on GitHub.
- Hereafter the comdevs testing module shall be referenced as testbed.
- Each testbed shall contain assets consisting of:
- An OTBM map file and it's adjunct metadata XML files.
- A single lua script file, conforming to the provided specification.
- A JSON file containing both the GitHub and OTLand identities of the comdev.
- Each map shall be precisely a given set of dimensions, to be determined, to facilitate programmatic stitching.
- Each map shall contain a statically located room, to be determined, to act as global entrypoint for the comdev testbed.
- It is self evident such testbeds will require their own scripts, so arrangements shall be made:
- The inquisition shall allow for the inclusion of exactly one Lua script file foreign to the native TFS base dataset.
- This single Lua script file shall hereafter be referenced as the rootscript.
- The rootscript shall be the collective merger of the comdev provided testbed script assets.
- The foundation of the rootscript shall consist of a header block providing facilities for the testbed script assets.
- The facilities provided shall conform to these specifications:
- There shall be exactly one global variable foreign to the native TFS base dataset.
- This header block shall harbor this global variable
- This global variable shall be a table to act as the inquisition script namespace.
- This global variable should be called PROVING_GROUNDS.
- The comdev testbed script assets will be appended to the rootscript after the header block in sequence.
- To facilitate this collaborative globbing of Lua, the testbed script assets shall conform to these specifications:
- The testbed provided script assets shall be in the form of an immediately invoked function expression (IIFE)
- The invoked function expression closure shall be decorated with the identity of the comdev.
- Hereafter the contents of the testbed function expression closure shall be referenced as proof.
- The proof shall consist entirely of TFS API calls, standard Lua 5.1, and RaptorJIT provided bit lib.
- Modification of XML indices shall not be allowed. The proof must use Revscriptsys facilities.
- The proof shall namespace itself under the inquisition script namespace.
- The proof should further namespace itself under a variable matching the comdev identity.
I have more but I've been at this a while.
But the general idea is you can
provide a test suite for your PR to
facilitate it's merger.