def _test__port_action_good_action(self, action, port, expected_call):
        self.callbacks._port_action(self.plugin, mock.Mock(),
                                    port, action)
        if action == 'create_port':
            self.utils.assert_called_once_with(mock.ANY, mock.ANY, mock.ANY)
        else:
            self.plugin.assert_has_calls([expected_call])
dataset/ETHPy150Open openstack/neutron/neutron/tests/unit/api/rpc/handlers/test_dhcp_rpc.py/TestDhcpRpcCallback._test__port_action_good_action/original