hotdoc: Fix has_extensions when several extensions are passed in

pull/4524/head
Thibault Saunier 6 years ago committed by Jussi Pakkanen
parent 27ff79e026
commit 301df38816
  1. 2
      mesonbuild/modules/hotdoc.py
  2. 6
      test cases/frameworks/23 hotdoc/meson.build

@ -379,7 +379,7 @@ class HotDocModule(ExtensionModule):
@noKwargs @noKwargs
def has_extensions(self, state, args, kwargs): def has_extensions(self, state, args, kwargs):
res = self.hotdoc.run_hotdoc(['--has-extension'] + args) == 0 res = self.hotdoc.run_hotdoc(['--has-extension=%s' % extension for extension in args]) == 0
return ModuleReturnValue(res, [res]) return ModuleReturnValue(res, [res])
def generate_doc(self, state, args, kwargs): def generate_doc(self, state, args, kwargs):

@ -7,3 +7,9 @@ endif
subdir('doc') subdir('doc')
assert(hotdoc.has_extensions(['gi-extension']) == true,
'GI extension should always be found.')
assert(hotdoc.has_extensions(['gi-extension', 'no-way-you-exist-extension']) == false,
'A hotdoc extension called "no-way-you-exist-extension" should never be found.')

Loading…
Cancel
Save