~ubuntu-branches/ubuntu/saucy/nova/saucy-proposed

« back to all changes in this revision

Viewing changes to nova/tests/api/openstack/compute/contrib/test_instance_usage_audit_log.py

  • Committer: Package Import Robot
  • Author(s): Chuck Short, Chuck Short, Adam Gandelman
  • Date: 2013-02-22 09:27:29 UTC
  • mfrom: (1.1.68)
  • Revision ID: package-import@ubuntu.com-20130222092729-nn3gt8rf97uvts77
Tags: 2013.1.g3-0ubuntu1
[ Chuck Short ]
* New usptream release. 
* debian/patches/debian/patches/fix-ubuntu-tests.patch: Refreshed.
* debian/nova-baremetal.logrotate: Fix logfile path.
* debian/control, debian/nova-spiceproxy.{install, logrotate, upstart}:
  Add spice html5 proxy support.
* debian/nova-novncproxy.upstart: Start on runlevel [2345]
* debian/rules: Call testr directly since run_tests.sh -N gives weird return
  value when tests pass.
* debian/pyddist-overrides: Add websockify.
* debian/nova-common.postinst: Removed config file conversion, since
  the option is no longer available. (LP: #1110567)
* debian/control: Add python-pyasn1 as a dependency.
* debian/control: Add python-oslo-config as a dependency.
* debian/control: Suggest sysfsutils, sg3-utils, multipath-tools for fibre
  channel support.

[ Adam Gandelman ]
* debian/control: Fix typo (websocikfy -> websockify).

Show diffs side-by-side

added added

removed removed

Lines of Context:
80
80
    ]
81
81
 
82
82
 
83
 
def fake_service_get_all(context):
84
 
    return TEST_COMPUTE_SERVICES
85
 
 
86
 
 
87
 
def fake_task_log_get_all(context, task_name, begin, end):
 
83
def fake_task_log_get_all(context, task_name, begin, end,
 
84
                          host=None, state=None):
88
85
    assert task_name == "instance_usage_audit"
89
86
 
90
87
    if begin == begin1 and end == end1:
114
111
        self.context = context.get_admin_context()
115
112
        timeutils.set_time_override(datetime.datetime(2012, 7, 5, 10, 0, 0))
116
113
        self.controller = ial.InstanceUsageAuditLogController()
 
114
        self.host_api = self.controller.host_api
 
115
 
 
116
        def fake_service_get_all(context, disabled):
 
117
            self.assertTrue(disabled is None)
 
118
            return TEST_COMPUTE_SERVICES
117
119
 
118
120
        self.stubs.Set(utils, 'last_completed_audit_period',
119
121
                            fake_last_completed_audit_period)
120
122
        self.stubs.Set(db, 'service_get_all',
121
 
                            fake_service_get_all)
 
123
                       fake_service_get_all)
122
124
        self.stubs.Set(db, 'task_log_get_all',
123
 
                            fake_task_log_get_all)
 
125
                       fake_task_log_get_all)
124
126
 
125
127
    def tearDown(self):
126
128
        super(InstanceUsageAuditLogTest, self).tearDown()