zuul/tests
James E. Blair ec7ff30198 Provide file locations of config syntax errors
Yaml parse errors come with nice pointers for the line and column
in the file where the error occurred.  Provide the same for
Zuul configuration language syntax errors.

This adds a yaml.Mark object (which points to a file location) to
each top-level zuul configuration object.  We could add it to every
dictionary we parse, but at the moment, that seems excessive.

This uses the same mechanism to add the already existing zuul
source context to the same objects, and retires the previous method.

The new error message looks like:

----
Zuul encountered a syntax error while parsing its configuration in the
repo org/project on branch master.  The error was:

  extra keys not allowed @ data['foo']

The error appears in a job stanza with the content:

  {'foo': 'error', 'name': 'project-test2'}

  in "org/project/.zuul.yaml@master", line 2, column 3:
    - job:
      ^
----

Change-Id: Iea496a9dca6d4cef51854afc5d3e042b3b99411a
2017-03-06 13:44:10 -08:00
..
fixtures Add a test for a broken config on startup 2017-03-06 13:44:10 -08:00
nodepool Supply label name to Nodes 2017-02-13 13:04:39 -05:00
unit Provide file locations of config syntax errors 2017-03-06 13:44:10 -08:00
__init__.py Add non-voting jobs. 2012-08-23 23:20:09 +00:00
base.py Add a test for a broken config on startup 2017-03-06 13:44:10 -08:00
make_playbooks.py Add a test for a broken config on startup 2017-03-06 13:44:10 -08:00
print_layout.py Add playbooks for all test jobs 2017-02-03 14:23:58 -08:00