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
Where the root folders are test cases with loaded file being the main.nyan (which may include import statements) and in the sim (= simulation) folders there are files with commands in order to simulate a scenario. Every line is command, mainly assert like commands but also execution of patches.
// optionally set a namespacenamespacemain// assertsBarrackscreates==[main.Jedi,main.Clone]Barrackshp==4000Barracksmodel==./models/m1.dat// assert number of membersUnit # 3Infantry # 3Jedihp==300Masterhp==480// apply a patchpatchArmorUpgradeJedihp==310Masterhp==490
I'd adapt the syntax a slight little bit though: instead of Barracks creates I'd use Barracks.creates or Barracks:creates. That should also simplify parsing a bit, because space # then is always # and member access is uniquely formatted.
This could be extended with API-specific tests that can assert whether our state transitions for game entities are correct and whether AvalabilityRequirement and Condition work like they should.
A suggestion for testing (what I am using in jnyan):
Where the root folders are test cases with loaded file being the main.nyan (which may include import statements) and in the sim (= simulation) folders there are files with commands in order to simulate a scenario. Every line is command, mainly assert like commands but also execution of patches.
Source: jnyan/src/test/resources/tests/000
The text was updated successfully, but these errors were encountered: