(self)
| 103 | os.makedirs(self.env.server_logs_dir) |
| 104 | |
| 105 | def _make_conf(self): |
| 106 | # remove anything from another run/test suite |
| 107 | conf_dest_dir = os.path.join(self.env.server_dir, 'conf') |
| 108 | if os.path.isdir(conf_dest_dir): |
| 109 | shutil.rmtree(conf_dest_dir) |
| 110 | for d in self._source_dirs: |
| 111 | conf_src_dir = os.path.join(d, 'conf') |
| 112 | if os.path.isdir(conf_src_dir): |
| 113 | if not os.path.exists(conf_dest_dir): |
| 114 | os.makedirs(conf_dest_dir) |
| 115 | for name in os.listdir(conf_src_dir): |
| 116 | src_path = os.path.join(conf_src_dir, name) |
| 117 | m = re.match(r'(.+).template', name) |
| 118 | if m: |
| 119 | self._make_template(src_path, os.path.join(conf_dest_dir, m.group(1))) |
| 120 | elif os.path.isfile(src_path): |
| 121 | shutil.copy(src_path, os.path.join(conf_dest_dir, name)) |
| 122 | |
| 123 | def _make_template(self, src, dest): |
| 124 | var_map = dict() |
no test coverage detected