~ubuntu-cloud-archive/ubuntu/precise/quantum/folsom

« back to all changes in this revision

Viewing changes to quantum/tests/unit/test_linux_dhcp.py

  • Committer: Package Import Robot
  • Author(s): Chuck Short, Adam Gandelman, Chuck Short
  • Date: 2012-09-12 13:41:20 UTC
  • mfrom: (2.1.12)
  • Revision ID: package-import@ubuntu.com-20120912134120-sheqxy7c2q5x7m34
Tags: 2012.2~rc1-0ubuntu1
[ Adam Gandelman ]
* debain/*.postrm: Fix argument-less calls to update-rc.d, redirect
  to /dev/null.  (LP: #1047560)
* debian/quantum-server.upstart: Invoke start-stop-daemon properly.
  (LP: #1047404)
* debain/*.postrm, *.upstart: Ensure files are named for corresponding
  agent package, not plugin package.
* debian/control:
  - Group agents with plugins.
  - Fix some copy/paste mistakes.
  - Set dependencies between agents and corresponding plugins.
  - Recommend quantum-plugin-openvswitch for quantum-server.
  - Require the same version of quantum-common and python-quantum.
  - Add quantum-netns-cleanup utility to quantum-common.
* debian/patches/fix-quantum-configuration.patch: Use correct database
  for linuxbridge plugin, use OVS plugin by default, call quantum-rootwrap
  correctly. (LP: #1048668)
* Fix all use of /usr/sbin, things should go in /usr/bin.
* Remove dhcp and l3 plugins, they are not actually plugins.
* Rename packages quantum-plugin-{l3, dhcp}-agent to
  quantum-{l3, dhcp}-agent.
* debain/quantum-*-agent.upstart: Specify config files as a
  parameter to --config-file, specify log files for all.
* debian/*.logrotate: Add logrotate configs for server and agents.
* Install quantum_sudoers with quantum-common, not quantum-server.
* Install rootwrap filters only with the packages that require them.
* debian/*-agent.upstart: Specify --config-file=/etc/quantum/quantum.conf
  in addition to plugin-specific config.  Specify log files for all agents.
* Allow group 'adm' read access to /var/log/quantum.
* debian/quantum-server.postinst: Drop, all has been moved to quantum-common.
* Add packaging for quantum-plugin-nec.

[ Chuck Short ]
* New usptream release.

Show diffs side-by-side

added added

removed removed

Lines of Context:
331
331
 
332
332
        self.assertFalse(delegate.called)
333
333
        exp_args = ['ip', 'netns', 'exec', 'qdhcp-ns', 'kill', '-9', 5]
334
 
        self.execute.assert_called_once_with(exp_args, root_helper='sudo')
 
334
        self.execute.assert_called_once_with(exp_args, root_helper='sudo',
 
335
                                             check_exit_code=True)
335
336
 
336
337
    def test_disable(self):
337
338
        attrs_to_mock = dict([(a, mock.DEFAULT) for a in
348
349
 
349
350
        delegate.assert_has_calls([mock.call.destroy(network, 'tap0')])
350
351
        exp_args = ['ip', 'netns', 'exec', 'qdhcp-ns', 'kill', '-9', 5]
351
 
        self.execute.assert_called_once_with(exp_args, root_helper='sudo')
 
352
        self.execute.assert_called_once_with(exp_args, root_helper='sudo',
 
353
                                             check_exit_code=True)
352
354
 
353
355
    def test_pid(self):
354
356
        with mock.patch('__builtin__.open') as mock_open:
452
454
                dm.spawn_process()
453
455
                self.assertTrue(mocks['_output_opts_file'].called)
454
456
                self.execute.assert_called_once_with(expected,
455
 
                                                     root_helper='sudo')
 
457
                                                     root_helper='sudo',
 
458
                                                     check_exit_code=True)
456
459
 
457
460
    def test_spawn(self):
458
461
        self._test_spawn([])
539
542
 
540
543
        self.safe.assert_has_calls([mock.call(exp_host_name, exp_host_data),
541
544
                                    mock.call(exp_opt_name, exp_opt_data)])
542
 
        self.execute.assert_called_once_with(exp_args, root_helper='sudo')
 
545
        self.execute.assert_called_once_with(exp_args, root_helper='sudo',
 
546
                                             check_exit_code=True)
543
547
 
544
548
    def _test_lease_relay_script_helper(self, action, lease_remaining,
545
549
                                        path_exists=True):