Example #1
0
def check_ebtables():
    result = checks.ebtables_supported()
    if not result:
        LOG.error(
            _LE('Cannot run ebtables. Please ensure that it '
                'is installed.'))
    return result
def check_ebtables():
    result = checks.ebtables_supported()
    if not result:
        LOG.error(_LE('Cannot run ebtables. Please ensure that it '
                      'is installed.'))
    return result
Example #3
0
    def test_ebtables_sanity_check(self):
        self.assertTrue(ebtables_supported())
        self.execute.assert_has_calls([mock.call(['ebtables', '--version'])])

        self.execute.side_effect = RuntimeError
        self.assertFalse(ebtables_supported())