Skip to content

Commit

Permalink
wrap: Add failing unit test for fallback consistency
Browse files Browse the repository at this point in the history
Dependency 'foo' is overriden with 'foo_dep' so using fallback variable
name 'bar_dep' should abort.
  • Loading branch information
xclaesse committed Jul 1, 2020
1 parent 7c90639 commit 5764939
Show file tree
Hide file tree
Showing 4 changed files with 22 additions and 0 deletions.
3 changes: 3 additions & 0 deletions test cases/failing/106 fallback consistency/meson.build
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
project('fallback consistency')

dependency('foo')
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
[wrap-file]
source_url = http://host.invalid/foo.tar.gz
source_filename = foo.tar.gz

[provide]
foo = bar_dep
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
project('sub')

foo_dep = declare_dependency()
meson.override_dependency('foo', foo_dep)

bar_dep = declare_dependency()
7 changes: 7 additions & 0 deletions test cases/failing/106 fallback consistency/test.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
{
"stdout": [
{
"line": "test cases/failing/106 fallback consistency/meson.build:3:0: ERROR: Inconsistency: Subproject has overridden the dependency with another variable than 'bar_dep'"
}
]
}

0 comments on commit 5764939

Please sign in to comment.