diff options
| author | Eli Schwartz <eschwartz@archlinux.org> | 2023-04-18 14:49:05 -0400 |
|---|---|---|
| committer | Eli Schwartz <eschwartz@archlinux.org> | 2023-04-18 19:42:29 -0400 |
| commit | 7bdb4a6926db5d89e930a64fe8206b0d575a74f9 (patch) | |
| tree | 50a8412f4332e217801909a7bef007a017e211fd /test cases/common/44 pkgconfig-gen | |
| parent | 4cd4f987708d5444a1cf59be14f2774b9f35f940 (diff) | |
| download | meson-7bdb4a6926db5d89e930a64fe8206b0d575a74f9.tar.gz | |
pkgconfig module: fix traceback on invalid missing description
If the optional first "mainlib" argument is there, then we infer several
values. Otherwise, some of those values fall back to a generic default,
and two of them -- name and description -- fall back to being mandatory.
In commit e84f293f672a372d2434d0ce4fa39d3f902b6ce8, we removed
validation for description as part of refactoring that never actually
validated anything.
Diffstat (limited to 'test cases/common/44 pkgconfig-gen')
| -rw-r--r-- | test cases/common/44 pkgconfig-gen/meson.build | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/test cases/common/44 pkgconfig-gen/meson.build b/test cases/common/44 pkgconfig-gen/meson.build index e093e6f87..6e84bb131 100644 --- a/test cases/common/44 pkgconfig-gen/meson.build +++ b/test cases/common/44 pkgconfig-gen/meson.build @@ -176,3 +176,12 @@ pkgg.generate( description : 'Check that variables can be single string', variables: 'foo=bar', ) + +# without a mainlib, name/description are mandatory +testcase expect_error('pkgconfig.generate: if a library is not passed as a positional argument, the \'name\' keyword argument is required.') + pkgg.generate(description: 'empty data') +endtestcase + +testcase expect_error('pkgconfig.generate: if a library is not passed as a positional argument, the \'description\' keyword argument is required.') + pkgg.generate(name: 'foobar') +endtestcase |
