ariatosca-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From mxm...@apache.org
Subject incubator-ariatosca git commit: changed argument name in storage
Date Thu, 20 Oct 2016 15:31:10 GMT
Repository: incubator-ariatosca
Updated Branches:
  refs/heads/wf-wip 606f2364a -> 02c86a404


changed argument name in storage


Project: http://git-wip-us.apache.org/repos/asf/incubator-ariatosca/repo
Commit: http://git-wip-us.apache.org/repos/asf/incubator-ariatosca/commit/02c86a40
Tree: http://git-wip-us.apache.org/repos/asf/incubator-ariatosca/tree/02c86a40
Diff: http://git-wip-us.apache.org/repos/asf/incubator-ariatosca/diff/02c86a40

Branch: refs/heads/wf-wip
Commit: 02c86a404c821fbcc7092a5315774cefceaa20f9
Parents: 606f236
Author: mxmrlv <mxmrlv@gmail.com>
Authored: Thu Oct 20 18:30:52 2016 +0300
Committer: mxmrlv <mxmrlv@gmail.com>
Committed: Thu Oct 20 18:30:52 2016 +0300

----------------------------------------------------------------------
 aria/__init__.py                    | 2 +-
 aria/storage/__init__.py            | 6 +++---
 tests/storage/test_model_storage.py | 4 ++--
 3 files changed, 6 insertions(+), 6 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-ariatosca/blob/02c86a40/aria/__init__.py
----------------------------------------------------------------------
diff --git a/aria/__init__.py b/aria/__init__.py
index ed4e408..4d9b0f4 100644
--- a/aria/__init__.py
+++ b/aria/__init__.py
@@ -45,7 +45,7 @@ def application_model_storage(driver):
     assert isinstance(driver, ModelDriver)
     if driver not in _model_storage:
         _model_storage[driver] = ModelStorage(
-            driver, models=[
+            driver, model_classes=[
                 models.Node,
                 models.NodeInstance,
                 models.Plugin,

http://git-wip-us.apache.org/repos/asf/incubator-ariatosca/blob/02c86a40/aria/storage/__init__.py
----------------------------------------------------------------------
diff --git a/aria/storage/__init__.py b/aria/storage/__init__.py
index 20c73a6..c5a7421 100644
--- a/aria/storage/__init__.py
+++ b/aria/storage/__init__.py
@@ -75,16 +75,16 @@ class ModelStorage(Storage):
     """
     Managing the models storage.
     """
-    def __init__(self, driver, models=(), **kwargs):
+    def __init__(self, driver, model_classes=(), **kwargs):
         """
         Simple storage client api for Aria applications.
         The storage instance defines the tables/documents/code api.
 
         :param ModelDriver driver: model storage driver.
-        :param models: the models to register.
+        :param model_classes: the models to register.
         """
         assert isinstance(driver, ModelDriver)
-        super(ModelStorage, self).__init__(driver, models, **kwargs)
+        super(ModelStorage, self).__init__(driver, model_classes, **kwargs)
 
     def __getattr__(self, table):
         """

http://git-wip-us.apache.org/repos/asf/incubator-ariatosca/blob/02c86a40/tests/storage/test_model_storage.py
----------------------------------------------------------------------
diff --git a/tests/storage/test_model_storage.py b/tests/storage/test_model_storage.py
index cb5b4d8..a06cd5f 100644
--- a/tests/storage/test_model_storage.py
+++ b/tests/storage/test_model_storage.py
@@ -107,7 +107,7 @@ def test_storage_pointers():
         id = Field()
         pointing_field = PointerField(type=PointedModel)
 
-    storage = ModelStorage(InMemoryModelDriver(), models=[PointingModel])
+    storage = ModelStorage(InMemoryModelDriver(), model_classes=[PointingModel])
     storage.setup()
 
     assert storage.pointed_model
@@ -136,7 +136,7 @@ def test_storage_iter_pointers():
         id = models.Field()
         pointing_field = structures.IterPointerField(type=PointedIterModel)
 
-    storage = ModelStorage(InMemoryModelDriver(), models=[PointingIterModel])
+    storage = ModelStorage(InMemoryModelDriver(), model_classes=[PointingIterModel])
     storage.setup()
 
     assert storage.pointed_iter_model


Mime
View raw message