summaryrefslogtreecommitdiffstats
path: root/test cases/warning/5 fallback consistency
diff options
context:
space:
mode:
Diffstat (limited to 'test cases/warning/5 fallback consistency')
-rw-r--r--test cases/warning/5 fallback consistency/meson.build4
-rw-r--r--test cases/warning/5 fallback consistency/subprojects/foo.wrap6
-rw-r--r--test cases/warning/5 fallback consistency/subprojects/foo/meson.build6
-rw-r--r--test cases/warning/5 fallback consistency/test.json10
4 files changed, 26 insertions, 0 deletions
diff --git a/test cases/warning/5 fallback consistency/meson.build b/test cases/warning/5 fallback consistency/meson.build
new file mode 100644
index 0000000..3af6ce8
--- /dev/null
+++ b/test cases/warning/5 fallback consistency/meson.build
@@ -0,0 +1,4 @@
+project('fallback consistency')
+
+# Subproject overrides foo with foo_dep but wrap file says it's bar_dep. This should warn.
+dependency('foo')
diff --git a/test cases/warning/5 fallback consistency/subprojects/foo.wrap b/test cases/warning/5 fallback consistency/subprojects/foo.wrap
new file mode 100644
index 0000000..28055d9
--- /dev/null
+++ b/test cases/warning/5 fallback consistency/subprojects/foo.wrap
@@ -0,0 +1,6 @@
+[wrap-file]
+source_url = http://host.invalid/foo.tar.gz
+source_filename = foo.tar.gz
+
+[provide]
+foo = bar_dep
diff --git a/test cases/warning/5 fallback consistency/subprojects/foo/meson.build b/test cases/warning/5 fallback consistency/subprojects/foo/meson.build
new file mode 100644
index 0000000..fb58a4a
--- /dev/null
+++ b/test cases/warning/5 fallback consistency/subprojects/foo/meson.build
@@ -0,0 +1,6 @@
+project('sub')
+
+foo_dep = declare_dependency()
+meson.override_dependency('foo', foo_dep)
+
+bar_dep = declare_dependency()
diff --git a/test cases/warning/5 fallback consistency/test.json b/test cases/warning/5 fallback consistency/test.json
new file mode 100644
index 0000000..8ab28d1
--- /dev/null
+++ b/test cases/warning/5 fallback consistency/test.json
@@ -0,0 +1,10 @@
+{
+ "stdout": [
+ {
+ "line": "WARNING: Inconsistency: Subproject has overridden the dependency with another variable than 'bar_dep'"
+ }
+ ],
+ "tools": {
+ "cmake": ">=3.14"
+ }
+}