wesnoth/data/test/_main.cfg
Steve Cotton aaf2735c1c Add [test_do_attack_by_id], a wrapper for [do_command][attack]
The new tag takes ids instead of needing coordinates. So instead of storing
units or hardcoding values, an attack can be done like this:

```
[test_do_attack_by_id]
	attacker=alice
	defender=bob
	weapon=0
[/test_do_attack_by_id]
```

Add a simpler unit for unit tests than the Elvish Archer / Orcish Grunt
combo, cherry-picked from gfgtdf's PR #7589. This is a unit with a 10x1
melee attack, and 0% defense on all terrains.

Remove the test race's undead_variation=
For testing custom plague abilities, this triggered a warning when
converting to any unit type that doesn't have variation_id=wolf,
restricting tests to using only Walking Corpse and Soulless.
2023-07-02 18:54:17 +02:00

103 lines
3.0 KiB
INI

#textdomain wesnoth-test
#ifndef DONT_RELOAD_CORE
{themes/}
# Load core wml for tests including macros and units
{core}
[textdomain]
name="wesnoth"
[/textdomain]
[textdomain]
name="wesnoth-lib"
[/textdomain]
#endif
[textdomain]
name="wesnoth-test"
[/textdomain]
#ifdef TEST
[binary_path]
path="data/test"
[/binary_path]
#Load test macros
{test/macros}
[lua]
code = "wesnoth.dofile 'test/lua/wml_tags.lua'"
[/lua]
# Load automated test scenarios.
#
# They can be run individually with Wesnoth's `-u` command line option, but are usually run by
# the run_wml_tests script based on the list in wml_test_schedule.
{test/scenarios/behavioral_tests}
{test/scenarios/cve_tests}
{test/scenarios/lua_tests}
{test/scenarios/lua_tests/ai}
{test/scenarios/lua_tests/filesystem}
{test/scenarios/lua_tests/functional}
{test/scenarios/lua_tests/gui}
{test/scenarios/lua_tests/gui/widget}
{test/scenarios/lua_tests/location_set}
{test/scenarios/lua_tests/mathx}
{test/scenarios/lua_tests/stringx}
{test/scenarios/lua_tests/wesnoth}
{test/scenarios/lua_tests/wesnoth/audio}
{test/scenarios/lua_tests/wesnoth/game_events}
{test/scenarios/lua_tests/wesnoth/interface}
{test/scenarios/lua_tests/wesnoth/map}
{test/scenarios/lua_tests/wesnoth/paths}
{test/scenarios/lua_tests/wesnoth/schedule}
{test/scenarios/lua_tests/wesnoth/sides}
{test/scenarios/lua_tests/wesnoth/sync}
{test/scenarios/lua_tests/wesnoth/units}
{test/scenarios/lua_tests/wml}
{test/scenarios/lua_tests/wml-utils}
{test/scenarios/macro_tests}
{test/scenarios/test_tests}
{test/scenarios/wml_tests/FilterWML}
{test/scenarios/wml_tests/ScenarioWML}
{test/scenarios/wml_tests/ScenarioWML/AiWML}
{test/scenarios/wml_tests/ScenarioWML/EffectWML}
{test/scenarios/wml_tests/ScenarioWML/EventWML}
{test/scenarios/wml_tests/ScenarioWML/EventWML/ActionWML}
{test/scenarios/wml_tests/ScenarioWML/EventWML/ActionWML/ConditionalActionsWML}
{test/scenarios/wml_tests/ScenarioWML/EventWML/ActionWML/DirectActionsWML}
{test/scenarios/wml_tests/ScenarioWML/EventWML/ActionWML/InterfaceActionsWML}
{test/scenarios/wml_tests/ScenarioWML/EventWML/ActionWML/InternalActionsWML}
{test/scenarios/wml_tests/ScenarioWML/MusicListWML}
{test/scenarios/wml_tests/ScenarioWML/SideWML}
{test/scenarios/wml_tests/ScenarioWML/TimeWML}
{test/scenarios/wml_tests/TerrainWML}
{test/scenarios/wml_tests/UnitsWML}
{test/scenarios/wml_tests/UnitsWML/AbilitiesWML}
{test/scenarios/wml_tests/UnitsWML/Attacks}
{test/scenarios/wml_tests/WesnothFormulaLanguage}
# Manual tests, to run with Wesnoth's `-t <testname>` option, or by binding a hotkey for the
# main menu's "Choose Test Scenario" option.
#
# Many of these are closer to workbenches than tests, allowing developers to do some action
# that isn't automated, and then to find out whether the result matched the expectation.
{test/scenarios/manual_tests}
# Some unit_types that are only used for tests.
{test/units.cfg}
#endif
#ifndef DONT_RELOAD_CORE
[binary_path]
path=data/core
[/binary_path]
{game_config.cfg}
#endif