def setUp(self):
        data_collector = DataCollector(config=config)

        self.data_after = utils.convert(data_collector.data_collector())

        file_name = config.rollback_params['data_file_names']['PRE']
        pre_file_path = os.path.join(self.cloudferry_dir, file_name)
        with open(pre_file_path, "r") as f:
            self.pre_data = yaml.load(f)
Esempio n. 2
0
    def setUp(self):
        data_collector = DataCollector(config=config)

        self.data_after = utils.convert(data_collector.data_collector())

        file_name = config.rollback_params['data_file_names']['PRE']
        pre_file_path = os.path.join(self.cloudferry_dir, file_name)
        with open(pre_file_path, "r") as f:
            self.pre_data = yaml.load(f)
Esempio n. 3
0
 def dump_data(self):
     file_name = self.config.rollback_params['data_file_names']['PRE']
     data = self.data_collector()
     with pkg_resources.resource_stream(__name__, file_name) as f:
         yaml.dump(utils.convert(data), f, default_flow_style=False)
Esempio n. 4
0
 def dump_data(self):
     file_name = self.config.rollback_params['data_file_names']['PRE']
     data = self.data_collector()
     with pkg_resources.resource_stream(__name__, file_name) as f:
         yaml.dump(utils.convert(data), f, default_flow_style=False)