commit 28529d5bb81b453ea7535dee93d9f3c36f240033 Author: Clark Boylan Date: Tue Aug 7 17:21:30 2012 -0700 Initial commit of the nose html output plugin. Should be working as is (but may require some hackery). More automagic to come once setup.py is written. diff --git a/.gitignore b/.gitignore new file mode 100644 index 0000000..0d20b64 --- /dev/null +++ b/.gitignore @@ -0,0 +1 @@ +*.pyc diff --git a/README b/README new file mode 100644 index 0000000..dcfa61e --- /dev/null +++ b/README @@ -0,0 +1,5 @@ +A plugin for nosetests that will write out test results to results.html. The +code is adapted from the example html output plugin at +https://github.com/nose-devs/nose/blob/master/examples/html_plugin/htmlplug.py +and the pyunit Html test runner at +http://tungwaiyip.info/software/HTMLTestRunner.html. diff --git a/htmloutput/__init__.py b/htmloutput/__init__.py new file mode 100644 index 0000000..e69de29 diff --git a/htmloutput/htmloutput.py b/htmloutput/htmloutput.py new file mode 100644 index 0000000..aec1d82 --- /dev/null +++ b/htmloutput/htmloutput.py @@ -0,0 +1,651 @@ +""" +A plugin for nosetests that will write out test results to results.html. The +code is adapted from the example html output plugin at +https://github.com/nose-devs/nose/blob/master/examples/html_plugin/htmlplug.py +and the pyunit Html test runner at +http://tungwaiyip.info/software/HTMLTestRunner.html + +Original HTMLTestRunner License: +------------------------------------------------------------------------ +Copyright (c) 2004-2007, Wai Yip Tung +All rights reserved. + +Redistribution and use in source and binary forms, with or without +modification, are permitted provided that the following conditions are +met: + +* Redistributions of source code must retain the above copyright notice, + this list of conditions and the following disclaimer. +* Redistributions in binary form must reproduce the above copyright + notice, this list of conditions and the following disclaimer in the + documentation and/or other materials provided with the distribution. +* Neither the name Wai Yip Tung nor the names of its contributors may be + used to endorse or promote products derived from this software without + specific prior written permission. + +THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS +IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED +TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A +PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER +OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, +EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, +PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR +PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF +LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING +NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS +SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. +""" + +import datetime +import os +import traceback +from nose.plugins import Plugin +from xml.sax import saxutils + +__version__ = "0.0.1" + +class TemplateData(object): + """ + Define a HTML template for report customerization and generation. + + Overall structure of an HTML report + + HTML + +------------------------+ + | | + | | + | | + | STYLESHEET | + | +----------------+ | + | | | | + | +----------------+ | + | | + | | + | | + | | + | | + | HEADING | + | +----------------+ | + | | | | + | +----------------+ | + | | + | REPORT | + | +----------------+ | + | | | | + | +----------------+ | + | | + | ENDING | + | +----------------+ | + | | | | + | +----------------+ | + | | + | | + | | + +------------------------+ + """ + + STATUS = { + 0: 'pass', + 1: 'fail', + 2: 'error', + } + + DEFAULT_TITLE = 'Unit Test Report' + DEFAULT_DESCRIPTION = '' + + # ------------------------------------------------------------------------ + # HTML Template + + HTML_TMPL = r""" + + + + %(title)s + + + %(stylesheet)s + + + + +%(heading)s +%(report)s +%(ending)s + + + +""" + # variables: (title, generator, stylesheet, heading, report, ending) + + + # ------------------------------------------------------------------------ + # Stylesheet + # + # alternatively use a for external style sheet, e.g. + # + + STYLESHEET_TMPL = """ + +""" + + + + # ------------------------------------------------------------------------ + # Heading + # + + HEADING_TMPL = """
+

%(title)s

+%(parameters)s +

%(description)s

+
+ +""" # variables: (title, parameters, description) + + HEADING_ATTRIBUTE_TMPL = """

%(name)s: %(value)s

+""" # variables: (name, value) + + + + # ------------------------------------------------------------------------ + # Report + # + + REPORT_TMPL = """ +

Show +Summary +Failed +All +

+ ++++++++ + + + + + + + + +%(test_list)s + + + + + + + + +
Test Group/Test caseCountPassFailErrorView
Total%(count)s%(Pass)s%(fail)s%(error)s 
+""" # variables: (test_list, count, Pass, fail, error) + + REPORT_CLASS_TMPL = r""" + + %(desc)s + %(count)s + %(Pass)s + %(fail)s + %(error)s + Detail + +""" # variables: (style, desc, count, Pass, fail, error, cid) + + + REPORT_TEST_WITH_OUTPUT_TMPL = r""" + +
%(desc)s
+ + + + + %(status)s + + + + + + +""" # variables: (tid, Class, style, desc, status) + + + REPORT_TEST_NO_OUTPUT_TMPL = r""" + +
%(desc)s
+ %(status)s + +""" # variables: (tid, Class, style, desc, status) + + + REPORT_TEST_OUTPUT_TMPL = r""" +%(id)s: %(output)s +""" # variables: (id, output) + + + + # ------------------------------------------------------------------------ + # ENDING + # + + ENDING_TMPL = """
 
""" + +# -------------------- The end of the Template class ------------------- + + +class HtmlOutput(Plugin): + """Output test results in html. + """ + + name = 'html-output' + score = 2 # run late + + def __init__(self): + super(HtmlOutput, self).__init__() + self.success_count = 0 + self.failure_count = 0 + self.error_count = 0 + self.result = [] + + def options(self, parser, env=os.environ): + super(HtmlOutput, self).options(parser, env) + parser.add_option("--html-out-file", action="store", + default=env.get('NOSE_HTML_OUT_FILE', 'results.html'), + dest="html_file", + metavar="FILE", + help="Produce results in the specified HTML file.") + + def configure(self, options, conf): + super(HtmlOutput, self).configure(options, conf) + self.html_file = None + if options.html_file: + self.html_file = options.html_file + + def begin(self): + self.startTime = datetime.datetime.now() + + def addSuccess(self, test): + self.success_count += 1 + output = test.shortDescription() + if output is None: + output = test.id() + self.result.append((0, test, output, '')) + + def addError(self, test, err): + self.error_count += 1 + _exc_str = self.formatErr(err) + output = test.shortDescription() + if output is None: + output = test.id() + self.result.append((2, test, output, _exc_str)) + + def addFailure(self, test, err): + self.failure_count += 1 + _exc_str = self.formatErr(err) + output = test.shortDescription() + if output is None: + output = test.id() + self.result.append((1, test, output, _exc_str)) + + def formatErr(self, err): + exctype, value, tb = err + return ''.join(traceback.format_exception(exctype, value, tb)) + + def setOutputStream(self, stream): + # grab for Monitoring + self.stream = stream + # return dummy stream + class dummy: + def write(self, *arg): + pass + def writeln(self, *arg): + pass + d = dummy() + #return d + + def report(self, stream): + self.stopTime = datetime.datetime.now() + report_attrs = self._getReportAttributes() + generator = 'html-output-plugin %s' % __version__ + heading = self._generate_heading(report_attrs) + report = self._generate_report() + ending = self._generate_ending() + output = TemplateData.HTML_TMPL % dict( + title = saxutils.escape(TemplateData.DEFAULT_TITLE), + generator = generator, + stylesheet = TemplateData.STYLESHEET_TMPL, + heading = heading, + report = report, + ending = ending, + ) + if self.html_file: + html_file = open(self.html_file, 'w') + html_file.write(output.encode('utf8')) + else: + stream.write(output.encode('utf8')) + + def _getReportAttributes(self): + """Return report attributes as a list of (name, value). + """ + startTime = str(self.startTime)[:19] + duration = str(self.stopTime - self.startTime) + status = [] + if self.success_count: + status.append('Pass %s' % self.success_count) + if self.failure_count: + status.append('Failure %s' % self.failure_count) + if self.error_count: + status.append('Error %s' % self.error_count ) + if status: + status = ' '.join(status) + else: + status = 'none' + return [ + ('Start Time', startTime), + ('Duration', duration), + ('Status', status), + ] + + def _generate_heading(self, report_attrs): + a_lines = [] + for name, value in report_attrs: + line = TemplateData.HEADING_ATTRIBUTE_TMPL % dict( + name = saxutils.escape(name), + value = saxutils.escape(value), + ) + a_lines.append(line) + heading = TemplateData.HEADING_TMPL % dict( + title = saxutils.escape(TemplateData.DEFAULT_TITLE), + parameters = ''.join(a_lines), + description = saxutils.escape(TemplateData.DEFAULT_DESCRIPTION), + ) + return heading + + def _generate_report(self): + rows = [] + sortedResult = self._sortResult(self.result) + for cid, (cls, cls_results) in enumerate(sortedResult): + # subtotal for a class + np = nf = ne = 0 + for n,t,o,e in cls_results: + if n == 0: np += 1 + elif n == 1: nf += 1 + else: ne += 1 + + # format class description + if cls.__module__ == "__main__": + name = cls.__name__ + else: + name = "%s.%s" % (cls.__module__, cls.__name__) + doc = cls.__doc__ and cls.__doc__.split("\n")[0] or "" + desc = doc and '%s: %s' % (name, doc) or name + + row = TemplateData.REPORT_CLASS_TMPL % dict( + style = ne > 0 and 'errorClass' or nf > 0 and 'failClass' or 'passClass', + desc = desc, + count = np+nf+ne, + Pass = np, + fail = nf, + error = ne, + cid = 'c%s' % (cid+1), + ) + rows.append(row) + + for tid, (n,t,o,e) in enumerate(cls_results): + self._generate_report_test(rows, cid, tid, n, t, o, e) + + report = TemplateData.REPORT_TMPL % dict( + test_list = ''.join(rows), + count = str(self.success_count + self.failure_count + self.error_count), + Pass = str(self.success_count), + fail = str(self.failure_count), + error = str(self.error_count), + ) + return report + + def _sortResult(self, result_list): + # unittest does not seems to run in any particular order. + # Here at least we want to group them together by class. + rmap = {} + classes = [] + for n,t,o,e in result_list: + cls = t.__class__ + if not rmap.has_key(cls): + rmap[cls] = [] + classes.append(cls) + rmap[cls].append((n,t,o,e)) + r = [(cls, rmap[cls]) for cls in classes] + return r + + def _generate_report_test(self, rows, cid, tid, n, t, o, e): + # e.g. 'pt1.1', 'ft1.1', etc + has_output = bool(o or e) + tid = (n == 0 and 'p' or 'f') + 't%s.%s' % (cid+1,tid+1) + name = t.id().split('.')[-1] + doc = t.shortDescription() or "" + desc = doc and ('%s: %s' % (name, doc)) or name + tmpl = has_output and TemplateData.REPORT_TEST_WITH_OUTPUT_TMPL or TemplateData.REPORT_TEST_NO_OUTPUT_TMPL + + # Comments below from the original source project. + # TODO: clean this up within the context of a nose plugin. + # o and e should be byte string because they are collected from stdout and stderr? + if isinstance(o,str): + # TODO: some problem with 'string_escape': it escape \n and mess up formating + # uo = unicode(o.encode('string_escape')) + uo = o.decode('latin-1') + else: + uo = o + if isinstance(e,str): + # TODO: some problem with 'string_escape': it escape \n and mess up formating + # ue = unicode(e.encode('string_escape')) + ue = e.decode('latin-1') + else: + ue = e + + script = TemplateData.REPORT_TEST_OUTPUT_TMPL % dict( + id = tid, + output = saxutils.escape(uo+ue), + ) + + row = tmpl % dict( + tid = tid, + Class = (n == 0 and 'hiddenRow' or 'none'), + style = n == 2 and 'errorCase' or (n == 1 and 'failCase' or 'none'), + desc = desc, + script = script, + status = TemplateData.STATUS[n], + ) + rows.append(row) + if not has_output: + return + + def _generate_ending(self): + return TemplateData.ENDING_TMPL diff --git a/htmloutput/nose_wrapper.py b/htmloutput/nose_wrapper.py new file mode 100644 index 0000000..7d7649a --- /dev/null +++ b/htmloutput/nose_wrapper.py @@ -0,0 +1,5 @@ +import nose +from htmloutput import HtmlOutput + +if __name__ == '__main__': + nose.main(addplugins=[HtmlOutput()]) diff --git a/results.html b/results.html new file mode 100644 index 0000000..4c712a0 --- /dev/null +++ b/results.html @@ -0,0 +1,5468 @@ + + + + + Unit Test Report + + + + + + + + + +
+

Unit Test Report

+

Start Time: 2012-08-07 17:14:53

+

Duration: 0:00:03.959132

+

Status: Pass 212 Failure 1 Error 3

+ +

+
+ + + +

Show +Summary +Failed +All +

+ ++++++++ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
Test Group/Test caseCountPassFailErrorView
nose.case.Test: The universal test case wrapper.21621213Detail
test_add_host
+ + + + pass + + + + +
test_create_aggregate
+ + + + pass + + + + +
test_delete_aggregate
+ + + + pass + + + + +
test_get_details
+ + + + pass + + + + +
test_list_aggregates
+ + + + pass + + + + +
test_remove_host
+ + + + pass + + + + +
test_set_metadata
+ + + + pass + + + + +
test_update
+ + + + pass + + + + +
test_update_with_availability_zone
+ + + + pass + + + + +
test_ambiguous_endpoints
+ + + + pass + + + + +
test_auth_redirect
+ + + + pass + + + + +
test_authenticate_failure
+ + + + pass + + + + +
test_authenticate_success
+ + + + pass + + + + +
test_auth_automatic
+ + + + pass + + + + +
test_auth_manual
+ + + + pass + + + + +
test_authenticate_failure
+ + + + pass + + + + +
test_authenticate_success
+ + + + pass + + + + +
test_create_cert
+ + + + pass + + + + +
test_get_root_cert
+ + + + pass + + + + +
test_create
+ + + + pass + + + + +
test_list_cloudpipes
+ + + + pass + + + + +
test_create
+ + + + pass + + + + +
test_create_ephemeral_defaults_to_zero
+ + + + pass + + + + +
test_delete
+ + + + pass + + + + +
test_find
+ + + + pass + + + + +
test_get_flavor_details
+ + + + pass + + + + +
test_get_flavor_details_diablo
+ + + + pass + + + + +
test_list_flavors
+ + + + pass + + + + +
test_list_flavors_undetailed
+ + + + pass + + + + +
test_create_private_domain
+ + + + pass + + + + +
test_create_public_domain
+ + + + pass + + + + +
test_delete_domain
+ + + + pass + + + + +
test_dns_domains
+ + + + pass + + + + +
test_create_entry
+ + + + pass + + + + +
test_delete_entry
+ + + + pass + + + + +
test_get_dns_entries_by_ip
+ + + + pass + + + + +
test_get_dns_entry_by_name
+ + + + pass + + + + +
test_list_floating_ips
+ + + + pass + + + + +
test_create_floating_ip
+ + + + pass + + + + +
test_create_floating_ip_with_pool
+ + + + pass + + + + +
test_delete_floating_ip
+ + + + pass + + + + +
test_list_floating_ips
+ + + + pass + + + + +
test_describe_resource
+ + + + pass + + + + +
test_host_reboot
+ + + + pass + + + + +
test_host_shutdown
+ + + + pass + + + + +
test_host_startup
+ + + + pass + + + + +
test_update_both
+ + + + pass + + + + +
test_update_enable
+ + + + pass + + + + +
test_update_maintenance
+ + + + pass + + + + +
test_hypervisor_detail
+ + + + pass + + + + +
test_hypervisor_get
+ + + + pass + + + + +
test_hypervisor_index
+ + + + pass + + + + +
test_hypervisor_search
+ + + + pass + + + + +
test_hypervisor_servers
+ + + + pass + + + + +
test_hypervisor_statistics
+ + + + pass + + + + +
test_hypervisor_uptime
+ + + + pass + + + + +
test_delete_image
+ + + + pass + + + + +
test_delete_meta
+ + + + pass + + + + +
test_find
+ + + + pass + + + + +
test_get_image_details
+ + + + pass + + + + +
test_list_images
+ + + + pass + + + + +
test_list_images_undetailed
+ + + + pass + + + + +
test_set_meta
+ + + + pass + + + + +
test_create_keypair
+ + + + pass + + + + +
test_delete_keypair
+ + + + pass + + + + +
test_import_keypair
+ + + + pass + + + + +
test_list_keypairs
+ + + + pass + + + + +
test_absolute_limits
+ + + + pass + + + + +
test_get_limits
+ + + + pass + + + + +
test_rate_limits
+ + + + pass + + + + +
test_class_quotas_get
+ + + + pass + + + + +
test_refresh_quota
+ + + + pass + + + + +
test_update_quota
+ + + + pass + + + + +
test_refresh_quota
+ + + + pass + + + + +
test_tenant_quotas_defaults
+ + + + pass + + + + +
test_tenant_quotas_get
+ + + + pass + + + + +
test_update_quota
+ + + + pass + + + + +
test_create_security_group
+ + + + pass + + + + +
test_delete_security_group_rule
+ + + + pass + + + + +
test_create_security_group
+ + + + pass + + + + +
test_delete_security_group
+ + + + pass + + + + +
test_get_security_groups
+ + + + pass + + + + +
test_list_security_groups
+ + + + pass + + + + +
test_refresh_security_group
+ + + + pass + + + + +
test_add_fixed_ip
+ + + + pass + + + + +
test_add_floating_ip
+ + + + pass + + + + +
test_add_security_group
+ + + + pass + + + + +
test_confirm_resized_server
+ + + + pass + + + + +
test_create_image
+ + + + pass + + + + +
test_create_server
+ + + + pass + + + + +
test_create_server_userdata_file_object
+ + + + pass + + + + +
test_delete_server
+ + + + pass + + + + +
test_delete_server_meta
+ + + + pass + + + + +
test_find
+ + + + pass + + + + +
test_get_console_output_with_length
+ + + + pass + + + + +
test_get_console_output_without_length
+ + + + pass + + + + +
test_get_server_actions
+ + + + pass + + + + +
test_get_server_details
+ + + + pass + + + + +
test_get_server_diagnostics
+ + + + pass + + + + +
test_get_vnc_console
+ + + + pass + + + + +
test_list_servers
+ + + + pass + + + + +
test_list_servers_undetailed
+ + + + pass + + + + +
test_live_migrate_server
+ + + + pass + + + + +
test_lock
+ + + + pass + + + + +
test_migrate_server
+ + + + pass + + + + +
test_reboot_server
+ + + + pass + + + + +
test_rebuild_server
+ + + + pass + + + + +
test_remove_fixed_ip
+ + + + pass + + + + +
test_remove_floating_ip
+ + + + pass + + + + +
test_remove_security_group
+ + + + pass + + + + +
test_rescue
+ + + + pass + + + + +
test_reset_state
+ + + + pass + + + + +
test_resize_server
+ + + + pass + + + + +
test_revert_resized_server
+ + + + pass + + + + +
test_set_server_meta
+ + + + pass + + + + +
test_start
+ + + + pass + + + + +
test_stop
+ + + + pass + + + + +
test_unlock
+ + + + pass + + + + +
test_unrescue
+ + + + pass + + + + +
test_update_server
+ + + + pass + + + + +
test_actions
+ + + + pass + + + + +
test_aggregate_add_host
+ + + + pass + + + + +
test_aggregate_create
+ + + + pass + + + + +
test_aggregate_delete
+ + + + pass + + + + +
test_aggregate_details
+ + + + pass + + + + +
test_aggregate_list
+ + + + pass + + + + +
test_aggregate_remove_host
+ + + + pass + + + + +
test_aggregate_set_metadata
+ + + + pass + + + + +
test_aggregate_update
+ + + + pass + + + + +
test_aggregate_update_with_availability_zone
+ + + + pass + + + + +
test_boot
+ + + + pass + + + + +
test_boot_files
+ + + + pass + + + + +
test_boot_hints
+ + + + pass + + + + +
test_boot_invalid_file
+ + + + pass + + + + +
test_boot_metadata
+ + + + pass + + + + +
test_boot_nics
+ + + + pass + + + + +
test_create_image
+ + + + pass + + + + +
test_delete
+ + + + pass + + + + +
test_diagnostics
+ + + + pass + + + + +
test_dns_create
+ + + + pass + + + + +
test_dns_create_private_domain
+ + + + pass + + + + +
test_dns_create_public_domain
+ + + + pass + + + + +
test_dns_delete
+ + + + pass + + + + +
test_dns_delete_domain
+ + + + pass + + + + +
test_dns_domains
+ + + + pass + + + + +
test_dns_list
+ + + + pass + + + + +
test_flavor_create
+ + + + pass + + + + +
test_flavor_delete
+ + + + pass + + + + +
test_flavor_list
+ + + + pass + + + + +
test_flavor_show
+ + + + pass + + + + +
test_host_reboot
+ + + + pass + + + + +
test_host_shutdown
+ + + + pass + + + + +
test_host_startup
+ + + + pass + + + + +
test_host_update_maintenance
+ + + + pass + + + + +
test_host_update_multiple_settings
+ + + + pass + + + + +
test_host_update_status
+ + + + pass + + + + +
test_hypervisor_list
+ + + + pass + + + + +
test_hypervisor_list_matching
+ + + + pass + + + + +
test_hypervisor_servers
+ + + + pass + + + + +
test_hypervisor_show
+ + + + pass + + + + +
test_hypervisor_stats
+ + + + pass + + + + +
test_hypervisor_uptime
+ + + + pass + + + + +
test_image_delete
+ + + + pass + + + + +
test_image_list
+ + + + pass + + + + +
test_image_meta_bad_action
+ + + + pass + + + + +
test_image_meta_del
+ + + + pass + + + + +
test_image_meta_set
+ + + + pass + + + + +
test_image_show
+ + + + pass + + + + +
test_list
+ + + + pass + + + + +
test_live_migration
+ + + + pass + + + + +
test_quota_class_show
+ + + + pass + + + + +
test_quota_class_update
+ + + + pass + + + + +
test_quota_defaults
+ + + + pass + + + + +
test_quota_show
+ + + + pass + + + + +
test_quota_update
+ + + + pass + + + + +
test_reboot
+ + + + pass + + + + +
test_rebuild
+ + + + pass + + + + +
test_rename
+ + + + pass + + + + +
test_reset_state
+ + + + pass + + + + +
test_resize
+ + + + pass + + + + +
test_resize_confirm
+ + + + pass + + + + +
test_resize_revert
+ + + + pass + + + + +
test_root_password
+ + + + pass + + + + +
test_set_meta_delete_dict
+ + + + pass + + + + +
test_set_meta_delete_keys
+ + + + pass + + + + +
test_set_meta_set
+ + + + pass + + + + +
test_show
+ + + + pass + + + + +
test_show_bad_id
+ + + + pass + + + + +
test_usage_list
+ + + + pass + + + + +
test_usage_get
+ + + + pass + + + + +
test_usage_list
+ + + + pass + + + + +
test_usage_list_detailed
+ + + + pass + + + + +
test_eq
+ + + + pass + + + + +
test_findall_invalid_attribute
+ + + + pass + + + + +
test_getid
+ + + + pass + + + + +
test_resource_lazy_getattr
+ + + + pass + + + + +
test_resource_repr
+ + + + pass + + + + +
test_get_client_class_unknown
+ + + + pass + + + + +
test_get_client_class_v1_1
+ + + + pass + + + + +
test_get_client_class_v2
+ + + + pass + + + + +
test_get_client_class_v2_int
+ + + + pass + + + + +
test_auth_failure
+ + + + error + + + + +
test_get
+ + + + error + + + + +
test_post
+ + + + error + + + + +
test_alternate_service_type
+ + + + pass + + + + +
test_building_a_service_catalog
+ + + + pass + + + + +
test_debug
+ + + + pass + + + + +
test_help
+ + + + pass + + + + +
test_help_on_subcommand
+ + + + fail + + + + +
test_help_unknown_command
+ + + + pass + + + + +
test_find_by_integer_id
+ + + + pass + + + + +
test_find_by_str_displayname
+ + + + pass + + + + +
test_find_by_str_id
+ + + + pass + + + + +
test_find_by_str_name
+ + + + pass + + + + +
test_find_by_uuid
+ + + + pass + + + + +
test_find_none
+ + + + pass + + + + +
Total21621213 
+ +
 
+ + + diff --git a/setup.py b/setup.py new file mode 100644 index 0000000..917538c --- /dev/null +++ b/setup.py @@ -0,0 +1,2 @@ +# TODO :) +# Be sure to add the entry point for the nose plugin.