Example #1
0
def getBaseConnectionArgsDict():
  """Return a dictonary of common database connection arguments."""
  return {
    "host": config.get("repository", "host"),
    "port": config.getint("repository", "port"),
    "user": config.get("repository", "user"),
    "passwd": config.get("repository", "passwd"),
    "charset": "utf8",
    "use_unicode": True,
  }
    def setUpClass(cls):
        cls.autostacksApp = TestApp(autostacks_api.app.wsgifunc())
        cls.cloudwatchApp = TestApp(cloudwatch_api.app.wsgifunc())
        cls.customApp = TestApp(custom_api.app.wsgifunc())
        cls.instancesApp = TestApp(instances_api.app.wsgifunc())
        cls.modelApp = TestApp(models_api.app.wsgifunc())
        cls.headers = getDefaultHTTPHeaders(htm.it.app.config)

        cls.plaintextPort = config.getint("metric_listener", "plaintext_port")
        cls.apiKey = config.get("security", "apikey")
Example #3
0
  def setUpClass(cls):
    cls.autostacksApp = TestApp(autostacks_api.app.wsgifunc())
    cls.cloudwatchApp = TestApp(cloudwatch_api.app.wsgifunc())
    cls.customApp = TestApp(custom_api.app.wsgifunc())
    cls.instancesApp = TestApp(instances_api.app.wsgifunc())
    cls.modelApp = TestApp(models_api.app.wsgifunc())
    cls.headers = getDefaultHTTPHeaders(htm.it.app.config)

    cls.plaintextPort = config.getint("metric_listener", "plaintext_port")
    cls.apiKey = config.get("security", "apikey")
Example #4
0
def getBaseConnectionArgsDict():
    """Return a dictonary of common database connection arguments."""
    return {
        "host": config.get("repository", "host"),
        "port": config.getint("repository", "port"),
        "user": config.get("repository", "user"),
        "passwd": config.get("repository", "passwd"),
        "charset": "utf8",
        "use_unicode": True,
    }