Fix some bugs when testing opensds ansible
[stor4nfv.git] / src / ceph / src / test / system / systest_settings.h
1 // -*- mode:C++; tab-width:8; c-basic-offset:2; indent-tabs-mode:t -*-
2 // vim: ts=8 sw=2 smarttab
3 /*
4  * Ceph - scalable distributed file system
5  *
6  * Copyright (C) 2011 New Dream Network
7  *
8  * This is free software; you can redistribute it and/or
9  * modify it under the terms of the GNU Lesser General Public
10  * License version 2.1, as published by the Free Software
11  * Foundation.  See file COPYING.
12  *
13  */
14
15 #ifndef CEPH_SYSTEM_TEST_SETTINGS_H
16 #define CEPH_SYSTEM_TEST_SETTINGS_H
17
18 #include <string>
19
20 /* Singleton with settings grabbed from environment variables */
21 class SysTestSettings
22 {
23 public:
24   static SysTestSettings& inst();
25   bool use_threads() const;
26   std::string get_log_name(const std::string &suffix) const;
27 private:
28   static SysTestSettings* m_inst;
29   SysTestSettings();
30   ~SysTestSettings();
31
32   bool m_use_threads;
33   std::string m_log_file_base;
34 };
35
36 #endif