Add .gitreview file.

Change-Id: I2e67ecf5a0b90c1d222bb5e20bda5d24f00c84b7
This commit is contained in:
Serg Melikyan 2013-05-14 16:02:03 +04:00
parent 17938ab9ca
commit 5b6c49e8b1
10 changed files with 26 additions and 11 deletions

4
.gitreview Normal file
View File

@ -0,0 +1,4 @@
[gerrit]
host=review.openstack.org
port=29418
project=stackforge/murano-api.git

View File

@ -11,4 +11,3 @@
# WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the # WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
# License for the specific language governing permissions and limitations # License for the specific language governing permissions and limitations
# under the License.from oslo.config import cfg # under the License.from oslo.config import cfg

View File

@ -11,4 +11,3 @@
# WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the # WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
# License for the specific language governing permissions and limitations # License for the specific language governing permissions and limitations
# under the License.from oslo.config import cfg # under the License.from oslo.config import cfg

View File

@ -14,8 +14,10 @@
import routes import routes
from muranoapi.openstack.common import wsgi from muranoapi.openstack.common import wsgi
from muranoapi.api.v1 import (environments, sessions, from muranoapi.api.v1 import environments
active_directories, webservers) from muranoapi.api.v1 import sessions
from muranoapi.api.v1 import active_directories
from muranoapi.api.v1 import webservers
class API(wsgi.Router): class API(wsgi.Router):

View File

@ -11,4 +11,3 @@
# WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the # WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
# License for the specific language governing permissions and limitations # License for the specific language governing permissions and limitations
# under the License.from oslo.config import cfg # under the License.from oslo.config import cfg

View File

@ -36,7 +36,7 @@ def compile_big_int_sqlite(type_, compiler, **kw):
class ModelBase(object): class ModelBase(object):
__protected_attributes__ = {"created", "updated"} __protected_attributes__ = set(["created", "updated"])
created = Column(DateTime, default=timeutils.utcnow, created = Column(DateTime, default=timeutils.utcnow,
nullable=False) nullable=False)
@ -79,8 +79,7 @@ class ModelBase(object):
def to_dict(self): def to_dict(self):
dictionary = self.__dict__.copy() dictionary = self.__dict__.copy()
return {k: v for k, v in dictionary.iteritems() return dict([(k, v) for k, v in dictionary.iteritems()])
if k != '_sa_instance_state'}
class JsonBlob(TypeDecorator): class JsonBlob(TypeDecorator):

View File

@ -14,6 +14,7 @@ pep8==1.3.3
sphinx>=1.1.2 sphinx>=1.1.2
requests requests
testtools>=0.9.22 testtools>=0.9.22
mock
# Optional packages that should be installed when testing # Optional packages that should be installed when testing
xattr>=0.6.0 xattr>=0.6.0

14
tox.ini
View File

@ -1,5 +1,5 @@
[tox] [tox]
envlist = py27,pep8 envlist = py26,py27,pep8,pyflakes
[testenv] [testenv]
setenv = VIRTUAL_ENV={envdir} setenv = VIRTUAL_ENV={envdir}
@ -44,3 +44,15 @@ commands = nosetests --cover-erase --cover-package=muranoapi --with-xcoverage
deps = file://{toxinidir}/.cache.bundle deps = file://{toxinidir}/.cache.bundle
setenv = NOSE_WITH_XUNIT=1 setenv = NOSE_WITH_XUNIT=1
commands = {posargs} commands = {posargs}
[testenv:pyflakes]
deps = flake8
commands = flake8
[flake8]
# H301 one import per line
# H302 import only modules
ignore = H301,H302
show-source = true
builtins = _
exclude=.venv,.git,.tox,dist,doc,*openstack/common*,*lib/python*,*egg,tools