2012-03-24 11:18:09 +00:00
|
|
|
#!/usr/bin/ruby -w
|
|
|
|
|
|
|
|
# T_357segment_info
|
|
|
|
describe "mkvmerge / segment info XML"
|
|
|
|
|
2013-10-19 11:08:26 +00:00
|
|
|
source = "data/subtitles/srt/ven.srt"
|
2012-03-27 17:32:23 +00:00
|
|
|
invalid = Dir["data/text/segment-info-invalid-*.xml"]
|
2012-03-24 11:18:09 +00:00
|
|
|
|
|
|
|
# Valid files:
|
2012-03-27 17:32:23 +00:00
|
|
|
(Dir["data/text/segment-info-*.xml"] - invalid).sort.each do |segment_info|
|
|
|
|
test_merge "#{source} --segmentinfo #{segment_info}"
|
2012-03-24 11:18:09 +00:00
|
|
|
end
|
|
|
|
|
|
|
|
# Invalid files:
|
2012-03-27 17:32:23 +00:00
|
|
|
invalid.sort.each do |segment_info|
|
2012-03-24 11:18:09 +00:00
|
|
|
test segment_info do
|
2012-03-27 17:32:23 +00:00
|
|
|
merge "#{source} --segmentinfo #{segment_info}", :exit_code => 2
|
2012-03-24 11:18:09 +00:00
|
|
|
:ok
|
|
|
|
end
|
|
|
|
end
|