Import gst-integration-testsuites
[platform/upstream/gstreamer.git] / subprojects / gst-integration-testsuites / testsuites / adaptive.py
1 # Pastebin PJeVxRyU
2 # -*- Mode: Python -*- vi:si:et:sw=4:sts=4:ts=4:syntax=python
3 #
4 # Copyright (c) 2014 Thibault Saunier <thibault.saunier@collabora.com>
5 # Copyright (c) 2017 Sebastian Droege <sebastian@centricular.com>
6 #
7 # This program is free software; you can redistribute it and/or
8 # modify it under the terms of the GNU Lesser General Public
9 # License as published by the Free Software Foundation; either
10 # version 2.1 of the License, or (at your option) any later version.
11 #
12 # This program is distributed in the hope that it will be useful,
13 # but WITHOUT ANY WARRANTY; without even the implied warranty of
14 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
15 # Lesser General Public License for more details.
16 #
17 # You should have received a copy of the GNU Lesser General Public
18 # License along with this program; if not, write to the
19 # Free Software Foundation, Inc., 51 Franklin St, Fifth Floor,
20 # Boston, MA 02110-1301, USA.
21
22 """
23 The GstValidate adaptive streams test-vectors testsuite
24 """
25
26 import os
27 from launcher.baseclasses import MediaFormatCombination
28
29 TEST_MANAGER = "validate"
30
31 BLACKLIST = [
32     ('validate.dash.playback.trick_mode_seeks.DASHIF_TestCases_2a_qualcomm_1_MultiResMPEG2',
33      'https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/issues/545'),
34     ('validate.dash.playback.trick_mode_seeks.DASHIF_TestCases_1a_netflix_exMPD_BIP_TC1',
35      'https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/issues/545'),
36 ]
37
38
39 def setup_tests(test_manager, options):
40     print("Setting up GstValidate Adaptive Streaming test-vectors tests")
41
42     assets_dir = os.path.abspath(os.path.join(os.path.dirname(__file__), "..", "medias", "adaptivecontent"))
43     options.add_paths(assets_dir)
44     test_manager.set_default_blacklist(BLACKLIST)
45     # test_manager.add_expected_issues(EXPECTED_ISSUES)
46     test_manager.register_defaults()
47     scenarios = test_manager.get_scenarios()
48     # Don't test generic tests that are already covered by the base validate runner
49     scenarios.remove("change_state_intensive")
50     # Scrubbing is a tad pointless/intensive for these suites (already covered elsewhere)
51     scenarios.remove("scrub_forward_seeking")
52     # Add keyunit trick mode testing
53     scenarios.append("trick_mode_seeks")
54     # Add live/seekable scenarios
55     scenarios.append("seek_end_live")
56     scenarios.append("full_live_rewind")
57     scenarios.append("play_15s_live")
58     test_manager.set_scenarios(scenarios)
59
60     return True