magnum/magnum/tests
houming-wang 98875345c2 Performance: leverage dict comprehension in PEP-0274
PEP-0274 introduced dict comprehensions to replace dict constructor
with a sequence of length-2 sequences, these are benefits copied
from [1]:
  The dictionary constructor approach has two distinct disadvantages
  from the proposed syntax though.  First, it isn't as legible as a
  dict comprehension.  Second, it forces the programmer to create an
  in-core list object first, which could be expensive.
Magnum does not support python 2.6, we can leverage this.
There is deep dive about PEP-0274[2] and basic tests about
performance[3].
Note: This commit doesn't handle dict constructor with kwagrs.
This commit also adds a hacking rule.

[1]http://legacy.python.org/dev/peps/pep-0274/
[2]http://doughellmann.com/2012/11/12/the-performance-impact-of-using
-dict-instead-of-in-cpython-2-7-2.html
[3]http://paste.openstack.org/show/480757/

Change-Id: I61992fa428d6760449afe3754b02506336e8b421
2015-12-03 22:02:02 -05:00
..
contrib Record diagnostic info from bay nodes 2015-11-23 17:14:21 -05:00
functional Merge "Functional: Raise Exception if bay created failed." 2015-12-02 22:15:10 +00:00
unit Performance: leverage dict comprehension in PEP-0274 2015-12-03 22:02:02 -05:00
__init__.py Remove redundant FunctionalTest class 2015-07-15 03:39:11 +08:00
base.py Merge "Remove coding:utf-8" 2015-09-23 16:26:55 +00:00
conf_fixture.py Code refactor for ConfFixture 2015-09-06 11:10:39 +08:00
fake_policy.py Modify admin_api policy rule 2015-10-09 20:12:58 +00:00
fakes.py Merge "Remove coding:utf-8" 2015-09-23 16:26:55 +00:00
policy_fixture.py Remove redundant code about fake_policy 2015-08-07 01:29:26 +00:00
utils.py Remove redundant code from magnum.test.utils 2015-07-20 21:53:12 +08:00