acrn-hypervisor/misc/config_tools/configurator/pyodide/tests.py
Junjie Mao 22a47fe795 config_tools: check XML file structures on load
This patch validates the structure of the XML files given before they are
further used by the rest of the configurator. With this validation process,
the configurator confirms the XML files are well-structured and can thus
access certain nodes and contents without checking their existence or data
types.

Upon validation failure, an alert will pop up informing the user that the
given XML file is ill-formed. No further details are given as of now
because we assume users should not care about the internal structure of
those files.

Tracked-On: #6691
Signed-off-by: Junjie Mao <junjie.mao@intel.com>
2022-05-19 09:31:46 +08:00

29 lines
807 B
Python

#!/usr/bin/env python3
__package__ = 'configurator.pyodide'
from .loadBoard import test as load_board_test
from .loadScenario import test as load_scenario_test
from .generateLaunchScript import test as generate_launch_script_test
from .validateBoardStructure import test as validate_board_structure_test
from .validateScenarioStructure import test as validate_scenario_structure_test
from .validateScenario import test as validate_scenario_test
from .populateDefaultValues import test as populate_default_values
def main():
load_board_test()
load_scenario_test()
generate_launch_script_test()
validate_board_structure_test()
validate_scenario_structure_test()
validate_scenario_test()
populate_default_values()
def test():
main()
if __name__ == '__main__':
test()