Пример #1
0
def suite():
  suite = unittest.TestSuite()
  suite.addTests(memory_test.suite())
  try:
    test_utils.init_appengine()
    import memcache_test
    suite.addTests(memcache_test.suite())
    import datastore_test
    suite.addTests(datastore_test.suite())
    import layered_test
    suite.addTests(layered_test.suite())
    try:
      test_utils.init_httplib2()
      import httplib2_test
      suite.addTests(httplib2_test.suite())
    except ImportError, e:
      raise e
  except Exception, e:
    logging.warning(e)
    logging.warning('memcache, datastore, and layered tests disabled.')
Пример #2
0
# Copyright 2009 DeWitt Clinton
#
#   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.

import test_utils
test_utils.init_appengine()

import cache_test
import unittest
import datastore


class ClientTest(cache_test.ClientTest):
  def __init__(self, *args, **kwargs):
    super(ClientTest, self).__init__(datastore.Client, *args, **kwargs)


def suite():
  suite = unittest.TestSuite()
  suite.addTests(unittest.makeSuite(ClientTest))
  return suite