Split out test_model model and logic into it's own module
authorSverre Rabbelier <srabbelier@gmail.com>
Fri, 06 Mar 2009 17:12:51 +0000
changeset 1688 f8457a410d1f
parent 1687 8203c805edc7
child 1689 72dd9688627c
Split out test_model model and logic into it's own module Patch by: Sverre Rabbelier
tests/app/soc/logic/models/test_base.py
tests/app/soc/logic/models/test_model.py
tests/app/soc/models/__init__.py
tests/app/soc/models/test_model.py
--- a/tests/app/soc/logic/models/test_base.py	Fri Mar 06 15:52:12 2009 +0000
+++ b/tests/app/soc/logic/models/test_base.py	Fri Mar 06 17:12:51 2009 +0000
@@ -23,24 +23,9 @@
 import unittest
 
 from google.appengine.api import users
-from google.appengine.ext import db
 
-from soc.logic.models import base
-
-
-class TestModel(db.Model):
-  """Simpel test model.
-  """
-
-  value = db.IntegerProperty()
-
-
-class TestModelLogic(base.Logic):
-  """Simple test logic.
-  """
-
-  def __init__(self):
-    super(TestModelLogic, self).__init__(TestModel)
+from tests.app.soc.logic.models.test_model import TestModelLogic
+from tests.app.soc.models.test_model import TestModel
 
 
 class UserTest(unittest.TestCase):
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/tests/app/soc/logic/models/test_model.py	Fri Mar 06 17:12:51 2009 +0000
@@ -0,0 +1,32 @@
+#!/usr/bin/python2.5
+#
+# Copyright 2009 the Melange authors.
+#
+# Licensed under the Apache License, Version 2.0 (the "License");
+# you may not use this file except in compliance with the License.
+# You may obtain a copy of the License at
+#
+#   http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+
+
+__authors__ = [
+  '"Sverre Rabbelier" <sverre@rabbelier.nl>',
+  ]
+
+
+from soc.logic.models import base
+from tests.app.soc.models.test_model import TestModel
+
+
+class TestModelLogic(base.Logic):
+  """Simple test logic.
+  """
+
+  def __init__(self):
+    super(TestModelLogic, self).__init__(TestModel)
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/tests/app/soc/models/test_model.py	Fri Mar 06 17:12:51 2009 +0000
@@ -0,0 +1,30 @@
+#!/usr/bin/python2.5
+#
+# Copyright 2009 the Melange authors.
+#
+# Licensed under the Apache License, Version 2.0 (the "License");
+# you may not use this file except in compliance with the License.
+# You may obtain a copy of the License at
+#
+#   http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+
+
+__authors__ = [
+  '"Sverre Rabbelier" <sverre@rabbelier.nl>',
+  ]
+
+
+from google.appengine.ext import db
+
+
+class TestModel(db.Model):
+  """Simpel test model.
+  """
+
+  value = db.IntegerProperty()