def setUp(self): self.jsn = baseline_reader.json_baseline_as_string(ADAPTER_PATH) self.adp = otio.adapters.read_from_string(self.jsn, 'otio_json') self.adp._json_path = os.path.join( baseline_reader.MODPATH, "baselines", ADAPTER_PATH )
def test_manifest(): full_baseline = baseline_reader.json_baseline_as_string(MANIFEST_PATH) with open(MAN_PATH, 'w') as fo: fo.write(full_baseline) man = otio.plugins.manifest_from_file(MAN_PATH) man._update_plugin_source(baseline_reader.path_to_baseline(MANIFEST_PATH)) return man
def create_manifest(): """Create a temporary manifest.""" full_baseline = baseline_reader.json_baseline_as_string(MANIFEST_PATH) temp_dir = tempfile.mkdtemp(prefix='test_otio_manifest') man_path = os.path.join(temp_dir, 'manifest') with open(man_path, 'w') as fo: fo.write(full_baseline) man = otio.plugins.manifest_from_file(man_path) man._update_plugin_source(baseline_reader.path_to_baseline(MANIFEST_PATH)) return man
def setUp(self): self.jsn = baseline_reader.json_baseline_as_string(ADAPTER_PATH) self.adp = otio.adapters.otio_json.read_from_string(self.jsn) self.adp._json_path = os.path.join(baseline_reader.MODPATH, "baselines", ADAPTER_PATH)
def setUp(self): self.man = utils.create_manifest() self.jsn = baseline_reader.json_baseline_as_string(LINKER_PATH) self.mln = otio.adapters.otio_json.read_from_string(self.jsn) self.mln._json_path = os.path.join(baseline_reader.MODPATH, "baselines", LINKER_PATH)