def get_config_updates_recursive(self): config_updates = self.config_updates.copy() for sr_path, subrunner in self.subrunners.items(): if not is_prefix(self.path, sr_path): continue update = subrunner.get_config_updates_recursive() if update: config_updates[rel_path(self.path, sr_path)] = update return config_updates
def test_rel_path(): assert rel_path("", "foo.bar.baz") == "foo.bar.baz" assert rel_path("foo", "foo.bar.baz") == "bar.baz" assert rel_path("foo.bar", "foo.bar.baz") == "baz" assert rel_path("foo.bar.baz", "foo.bar.baz") == "" assert rel_path("", "") == ""
def test_rel_path(): assert rel_path('', 'foo.bar.baz') == 'foo.bar.baz' assert rel_path('foo', 'foo.bar.baz') == 'bar.baz' assert rel_path('foo.bar', 'foo.bar.baz') == 'baz' assert rel_path('foo.bar.baz', 'foo.bar.baz') == '' assert rel_path('', '') == ''