Skip to content

Commit

Permalink
Subprojects should not inherit parent override
Browse files Browse the repository at this point in the history
This was the behaviour in 0.55.0, so this test was assuming a behaviour
change. Revert it to the behaviour we had in 0.55.0.
  • Loading branch information
xclaesse committed Oct 16, 2020
1 parent 7271b1e commit ed70c6d
Showing 1 changed file with 2 additions and 5 deletions.
7 changes: 2 additions & 5 deletions run_unittests.py
Original file line number Diff line number Diff line change
Expand Up @@ -8416,14 +8416,11 @@ def test_builtin_options_subprojects_overrides_buildfiles(self):
self.init(testcase, extra_args=['--native-file', config])
self.assertIn(cm.exception.stdout, 'Parent should override default_library')

def test_builtin_options_subprojects_inherits_parent_override(self):
def test_builtin_options_subprojects_dont_inherits_parent_override(self):
# If the buildfile says subproject(... default_library: shared), ensure that's overwritten
testcase = os.path.join(self.common_test_dir, '230 persubproject options')
config = self.helper_create_native_file({'built-in options': {'default_library': 'both'}})

with self.assertRaises(subprocess.CalledProcessError) as cm:
self.init(testcase, extra_args=['--native-file', config])
self.assertIn(cm.exception.stdout, 'Parent should override default_library')
self.init(testcase, extra_args=['--native-file', config])

def test_builtin_options_compiler_properties(self):
# the properties section can have lang_args, and those need to be
Expand Down

0 comments on commit ed70c6d

Please sign in to comment.