Added a test for missing output.layers

This commit is contained in:
Salvador E. Tropea 2020-05-26 13:52:04 -03:00
parent 103ef8b79e
commit 979b3bc0d7
2 changed files with 37 additions and 3 deletions

View File

@ -9,9 +9,11 @@ Tests various errors in the config file
- Incorrect name
- Inner.1, but no inner layers
- Inner_1 (malformed)
- No output.name
- No output.type
- No output.options
- No output:
- name
- type
- options
- layers
For debug information use:
pytest-3 --log-cli-level debug
@ -96,3 +98,10 @@ def test_no_options():
ctx.run(EXIT_BAD_CONFIG)
assert ctx.search_err("Output 'PDF' needs options")
ctx.clean_up()
def test_no_layers():
ctx = context.TestContext('ErrorNoLayers', '3Rs', 'error_no_layers', None)
ctx.run(EXIT_BAD_CONFIG)
assert ctx.search_err("You must specify the layers for `PDF`")
ctx.clean_up()

View File

@ -0,0 +1,25 @@
kiplot:
version: 1
outputs:
- name: PDF
comment: "PDF files"
type: pdf
dir: PDF
options:
exclude_edge_layer: false
exclude_pads_from_silkscreen: false
use_aux_axis_as_origin: false
plot_sheet_reference: false
plot_footprint_refs: true
plot_footprint_values: true
force_plot_invisible_refs_vals: false
tent_vias: true
check_zone_fills: true
# PDF options
drill_marks: small
mirror_plot: false
negative_plot: false
line_width: 0.01