Added style dependency in pcbdraw makefile target.
- Also now we make sure the style is an existent file.
This commit is contained in:
parent
80df7d76c7
commit
d1ef2c8cbf
|
|
@ -306,6 +306,6 @@ class PcbDraw(BaseOutput): # noqa: F821
|
|||
|
||||
def get_dependencies(self):
|
||||
files = super().get_dependencies()
|
||||
if isinstance(self.options.style, str):
|
||||
if isinstance(self.options.style, str) and os.path.isfile(self.options.style):
|
||||
files.append(self.options.style)
|
||||
return files
|
||||
|
|
|
|||
|
|
@ -602,7 +602,10 @@ def test_makefile_1(test_dir):
|
|||
deps = targets['pcb_render'].split(' ')
|
||||
assert len(deps) == 1, deps
|
||||
assert ctx.get_out_path(prj+'-top$.svg') in deps
|
||||
assert os.path.abspath(targets[targets['pcb_render']]) == ctx.board_file
|
||||
deps = targets[targets['pcb_render']].split(' ')
|
||||
assert len(deps) == 2
|
||||
assert os.path.relpath(ctx.board_file) in deps
|
||||
assert 'tests/data/html_style.css' in deps
|
||||
logging.debug('- Target `pcb_render` OK')
|
||||
# print_front target
|
||||
deps = targets['print_front'].split(' ')
|
||||
|
|
|
|||
|
|
@ -69,6 +69,7 @@ outputs:
|
|||
type: pcbdraw
|
||||
options:
|
||||
output: '%f-%i$.%x'
|
||||
style: 'tests/data/html_style.css'
|
||||
|
||||
- name: 'print_front'
|
||||
comment: "Print F.Cu+F.SilkS"
|
||||
|
|
|
|||
Loading…
Reference in New Issue