Sha256: 0bf018c53d1dafc298c8f5df062ef03d7c61f94908fd2826636645c602c38a63
Contents?: true
Size: 904 Bytes
Versions: 4
Compression:
Stored size: 904 Bytes
Contents
require_relative '../../test_helper' describe Mp4Renamer do let :renamer do Renamer.new end let :helper do FixtureHelper.new end before do helper.setup end after do helper.teardown # remove the file that we rename also if after the steps end describe '#rename' do it 'renames the file if metadata is valailable' do helper.sample_files.each do |file| result = renamer.rename(file) # the result must be available assert(result) # cleanup after each use FileUtils.rm_rf result end end end describe '#rename_once?' do it 'returns false if not already rename' do refute(renamer.rename_once?('sample.mp4')) refute(renamer.rename_once?('sample_12_34.mp4')) end it 'returns true if already rename' do assert(renamer.rename_once?('sample_12_34_12_34.mp4')) end end end
Version data entries
4 entries across 4 versions & 1 rubygems