<commit_before>#!/bin/sh

base_test()
{

test_begin $1

do_test "$MP4BOX -add $EXTERNAL_MEDIA_DIR/counter/counter_30s_I25_baseline_1280x720_512kbps.264 -new $TEMP_DIR/file.mp4" "dash-input-preparation"

#test bandwidth, time and init
do_test "$MP4BOX -dash 1000 -out $TEMP_DIR/file.mpd $TEMP_DIR/file.mp4$2" "$1-dash"

do_hash_test $TEMP_DIR/file.mpd "$1-hash-mpd"

do_hash_test $TEMP_DIR/$3.mp4 "$1-hash-init"

do_playback_test "$TEMP_DIR/file.mpd" "$1-play"

test_end

}

base_test "dash-template-bandwidth-time" ":bandwidth=600000 -profile live -segment-name test-\$Bandwidth\$-\$Time%05d\$\$Init=is\$" "test-600000-is"

base_test "dash-template-repid-number" ":id=myrep -profile live -segment-name test-\$RepresentationID\$-\$Number%d\$" "test-myrep-"

base_test "dash-template-baseurl-global-path" ":id=myrep -base-url some_dir/ -profile live -segment-name \$Path=some_dir/\$test-\$RepresentationID\$-\$Number%d\$" "some_dir/test-myrep-"

base_test "dash-template-baseurl-rep-path" ":id=myrep:baseURL=some_dir/ -profile live -segment-name \$Path=some_dir/\$test-\$RepresentationID\$-\$Number%d\$" "some_dir/test-myrep-"
<commit_msg>fixed dash template tests<commit_after>#!/bin/sh

base_test()
{

test_begin $1

do_test "$MP4BOX -add $EXTERNAL_MEDIA_DIR/counter/counter_30s_I25_baseline_1280x720_512kbps.264 -new $TEMP_DIR/file.mp4" "dash-input-preparation"

#test bandwidth, time and init
do_test "$MP4BOX -dash 1000 -out $TEMP_DIR/file.mpd $TEMP_DIR/file.mp4$2" "$1-dash"

do_hash_test $TEMP_DIR/file.mpd "$1-hash-mpd"

do_hash_test $TEMP_DIR/$3 "$1-hash-init"

do_hash_test $TEMP_DIR/$4 "$1-hash-seg"

do_playback_test "$TEMP_DIR/file.mpd" "$1-play"

test_end

}

base_test "dash-template-bandwidth-time" ":bandwidth=600000 -profile live -segment-name test-\$Bandwidth\$-\$Time%05d\$\$Init=is\$" "test-600000-is.mpd" "test-600000-00000.m4s"

base_test "dash-template-repid-number" ":id=myrep -profile live -segment-name test-\$RepresentationID\$-\$Number%d\$" "test-myrep-.mpd" "test-myrep-1.m4s"

base_test "dash-template-baseurl-global-path" ":id=myrep -base-url some_dir/ -profile live -segment-name \$Path=some_dir/\$test-\$RepresentationID\$-\$Number%d\$" "some_dir/test-myrep-.mpd" "some_dir/test-myrep-1.m4s"

base_test "dash-template-baseurl-rep-path" ":id=myrep:baseURL=some_dir/ -profile live -segment-name \$Path=some_dir/\$test-\$RepresentationID\$-\$Number%d\$" "some_dir/test-myrep-.mpd" "some_dir/test-myrep-1.m4s"

{'fraction_non_alphanumeric': 0.1833470057424118, 'fraction_numerical': 0.04634946677604594, 'mean_word_length': 5.0975, 'pattern_counts': {'":': 8, '<': 3, '<?xml version=': 0, '>': 3, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '793991', 'n_tokens_mistral': 1090, 'n_tokens_neox': 1019, 'n_words': 146}