diff options
author | Angelos Mouzakitis <a.mouzakitis@virtualopensystems.com> | 2023-10-10 14:33:42 +0000 |
---|---|---|
committer | Angelos Mouzakitis <a.mouzakitis@virtualopensystems.com> | 2023-10-10 14:33:42 +0000 |
commit | af1a266670d040d2f4083ff309d732d648afba2a (patch) | |
tree | 2fc46203448ddcc6f81546d379abfaeb323575e9 /meson/test cases/frameworks/23 hotdoc | |
parent | e02cda008591317b1625707ff8e115a4841aa889 (diff) |
Change-Id: Iaf8d18082d3991dec7c0ebbea540f092188eb4ec
Diffstat (limited to 'meson/test cases/frameworks/23 hotdoc')
5 files changed, 46 insertions, 0 deletions
diff --git a/meson/test cases/frameworks/23 hotdoc/doc/index.md b/meson/test cases/frameworks/23 hotdoc/doc/index.md new file mode 100644 index 000000000..ea5eeb106 --- /dev/null +++ b/meson/test cases/frameworks/23 hotdoc/doc/index.md @@ -0,0 +1 @@ +# Hello world! diff --git a/meson/test cases/frameworks/23 hotdoc/doc/meson.build b/meson/test cases/frameworks/23 hotdoc/doc/meson.build new file mode 100644 index 000000000..a09bff08d --- /dev/null +++ b/meson/test cases/frameworks/23 hotdoc/doc/meson.build @@ -0,0 +1,19 @@ +hotdoc = import('hotdoc') + +target = hotdoc.generate_doc( + 'foobar', + c_smart_index: true, + project_version: '0.1', + sitemap: 'sitemap.txt', + index: 'index.md', + c_sources: files('../../10 gtk-doc/include/foo.h'), + languages: ['c'], + install: true, +) + +assert(target.config_path() == target.full_path() + '.json', + 'Hotdoc config paths do not match.' +) + +assert(hotdoc.has_extensions('search') == true, + 'Extension "search" provided by hotdoc core should always be found') diff --git a/meson/test cases/frameworks/23 hotdoc/doc/sitemap.txt b/meson/test cases/frameworks/23 hotdoc/doc/sitemap.txt new file mode 100644 index 000000000..b82354a1d --- /dev/null +++ b/meson/test cases/frameworks/23 hotdoc/doc/sitemap.txt @@ -0,0 +1,3 @@ +index.md + c-index + diff --git a/meson/test cases/frameworks/23 hotdoc/meson.build b/meson/test cases/frameworks/23 hotdoc/meson.build new file mode 100644 index 000000000..dd3c92acd --- /dev/null +++ b/meson/test cases/frameworks/23 hotdoc/meson.build @@ -0,0 +1,15 @@ +project('hotdoc', 'c') + +hotdoc = find_program('hotdoc', required: false) +if not hotdoc.found() + error('MESON_SKIP_TEST hotdoc not found.') +endif + +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.') + diff --git a/meson/test cases/frameworks/23 hotdoc/test.json b/meson/test cases/frameworks/23 hotdoc/test.json new file mode 100644 index 000000000..8b7bd7ecc --- /dev/null +++ b/meson/test cases/frameworks/23 hotdoc/test.json @@ -0,0 +1,8 @@ +{ + "installed": [ + {"type": "dir", "file": "usr/share/doc/foobar/html"} + ], + "tools": { + "hotdoc": ">=0.1.0" + } +} |