'Testing the creation of the same interface, two times.
This simulates two plugins creating the host with the same interface
We should end up with just one interface in that host'

def test_create_interface_two_times(self):

    h1 = self.plugin.createAndAddHost('pepito', 'linux')
    i1 = self.plugin.createAndAddInterface(h1, '1.2.3.4')
    h2 = self.plugin.createAndAddHost('pepito', 'linux')
    i2 = self.plugin.createAndAddInterface(h2, '1.2.3.4')
    self._plugin_controller.last_command_information = self.cmdinfo
    self._plugin_controller.onCommandFinished()
    self._model_controller.processAllPendingActions()
    self.assertTrue((len(self._model_controller.getAllHosts()) == 1), 'The    controller    should    have    just    one    host')
    self.assertTrue((len(self._model_controller.getHost(h1).getAllInterfaces()) == 1), 'The    host    should    have    just    one    interface')
