Changeset 275513 in webkit
- Timestamp:
- Apr 6, 2021 6:38:16 AM (3 years ago)
- Location:
- trunk/Tools
- Files:
-
- 2 deleted
- 5 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/Tools/ChangeLog
r275506 r275513 1 2021-04-06 Philippe Normand <pnormand@igalia.com> 2 3 [GStreamer] Test harness should use a mock audio output device 4 https://bugs.webkit.org/show_bug.cgi?id=223888 5 6 Reviewed by Adrian Perez de Castro. 7 8 Prioritize the new fakeaudiosink over other platform sinks when running the layout and API 9 tests. Mute and volume handling will still be tested (mocked, actually) but no actual 10 rendering will be performed. 11 12 The pulseaudio "sanitizer" can't work with a pipewire-pulse server because dynamic module 13 (un)loading is heavily restricted in this new wrapper. Moreover relying on the default sinks 14 when running on desktop machines easily triggers unintended beeps when running the tests. 15 16 * Scripts/webkitpy/port/gtk.py: 17 (GtkPort.__init__): 18 (GtkPort.setup_test_run): 19 (GtkPort.setup_environ_for_server): 20 (GtkPort.clean_up_test_run): Deleted. 21 * Scripts/webkitpy/port/gtk_unittest.py: 22 (GtkPortTest): 23 (GtkPortTest.make_port): Deleted. 24 * Scripts/webkitpy/port/pulseaudio_sanitizer.py: Removed. 25 * Scripts/webkitpy/port/pulseaudio_sanitizer_mock.py: Removed. 26 * Scripts/webkitpy/port/wpe.py: 27 (WPEPort.setup_environ_for_server): 28 * Scripts/webkitpy/port/wpe_unittest.py: 29 (WPEPortTest): 30 (WPEPortTest.make_port): Deleted. 31 1 32 2021-04-06 Aakash Jain <aakash_jain@apple.com> 2 33 -
trunk/Tools/Scripts/webkitpy/port/gtk.py
r274474 r275513 39 39 from webkitpy.layout_tests.models.test_configuration import TestConfiguration 40 40 from webkitpy.port.base import Port 41 from webkitpy.port.pulseaudio_sanitizer import PulseAudioSanitizer42 41 from webkitpy.port.xvfbdriver import XvfbDriver 43 42 from webkitpy.port.westondriver import WestonDriver … … 57 56 def __init__(self, *args, **kwargs): 58 57 super(GtkPort, self).__init__(*args, **kwargs) 59 self._pulseaudio_sanitizer = PulseAudioSanitizer()60 58 self._display_server = self.get_option("display_server") 61 59 … … 109 107 def setup_test_run(self, device_type=None): 110 108 super(GtkPort, self).setup_test_run(device_type) 111 self._pulseaudio_sanitizer.unload_pulseaudio_module()112 109 113 110 if self.get_option("leaks"): 114 111 self._leakdetector.clean_leaks_files_from_results_directory() 115 116 def clean_up_test_run(self):117 super(GtkPort, self).clean_up_test_run()118 self._pulseaudio_sanitizer.restore_pulseaudio_module()119 112 120 113 def setup_environ_for_server(self, server_name=None): … … 130 123 self._copy_value_from_environ_if_set(environment, 'WEBKIT_DEBUG') 131 124 self._copy_value_from_environ_if_set(environment, 'WEBKIT_GST_USE_PLAYBIN3') 132 self._copy_value_from_environ_if_set(environment, 'PULSE_SERVER')133 self._copy_value_from_environ_if_set(environment, 'PULSE_CLIENTCONFIG')134 125 for gst_variable in ('DEBUG', 'DEBUG_DUMP_DOT_DIR', 'DEBUG_FILE', 'DEBUG_NO_COLOR', 135 126 'PLUGIN_SCANNER', 'PLUGIN_PATH', 'PLUGIN_SYSTEM_PATH', 'REGISTRY', 136 127 'PLUGIN_PATH_1_0'): 137 128 self._copy_value_from_environ_if_set(environment, 'GST_%s' % gst_variable) 129 130 gst_feature_rank_override = environment.get('GST_PLUGIN_FEATURE_RANK') 131 environment['GST_PLUGIN_FEATURE_RANK'] = 'fakeaudiosink:max' 132 if gst_feature_rank_override: 133 environment['GST_PLUGIN_FEATURE_RANK'] += ',%s' % gst_feature_rank_override 138 134 139 135 # Configure the software libgl renderer if jhbuild ready and we test inside a virtualized window system -
trunk/Tools/Scripts/webkitpy/port/gtk_unittest.py
r274474 r275513 37 37 from webkitpy.port.config import clear_cached_configuration 38 38 from webkitpy.port.gtk import GtkPort 39 from webkitpy.port.pulseaudio_sanitizer_mock import PulseAudioSanitizerMock40 39 from webkitpy.port import port_testcase 41 40 from webkitpy.thirdparty.mock import Mock … … 48 47 port_name = 'gtk' 49 48 port_maker = GtkPort 50 51 # Additionally mocks out the PulseAudioSanitizer methods.52 def make_port(self, host=None, port_name=None, options=None, os_name=None, os_version=None, **kwargs):53 port = super(GtkPortTest, self).make_port(host, port_name, options, os_name, os_version, **kwargs)54 port._pulseaudio_sanitizer = PulseAudioSanitizerMock()55 return port56 49 57 50 def test_default_baseline_search_path(self): -
trunk/Tools/Scripts/webkitpy/port/wpe.py
r272643 r275513 98 98 'PLUGIN_PATH_1_0'): 99 99 self._copy_value_from_environ_if_set(environment, 'GST_%s' % gst_variable) 100 101 gst_feature_rank_override = environment.get('GST_PLUGIN_FEATURE_RANK') 102 environment['GST_PLUGIN_FEATURE_RANK'] = 'fakeaudiosink:max' 103 if gst_feature_rank_override: 104 environment['GST_PLUGIN_FEATURE_RANK'] += ',%s' % gst_feature_rank_override 105 100 106 return environment 101 107 -
trunk/Tools/Scripts/webkitpy/port/wpe_unittest.py
r265883 r275513 36 36 from webkitpy.port.config import clear_cached_configuration 37 37 from webkitpy.port.wpe import WPEPort 38 from webkitpy.port.pulseaudio_sanitizer_mock import PulseAudioSanitizerMock39 38 from webkitpy.port import port_testcase 40 39 from webkitpy.thirdparty.mock import Mock … … 45 44 port_name = 'wpe' 46 45 port_maker = WPEPort 47 48 # Additionally mocks out the PulseAudioSanitizer methods.49 def make_port(self, host=None, port_name=None, options=None, os_name=None, os_version=None, **kwargs):50 port = super(WPEPortTest, self).make_port(host, port_name, options, os_name, os_version, **kwargs)51 port._pulseaudio_sanitizer = PulseAudioSanitizerMock()52 return port53 46 54 47 def test_default_baseline_search_path(self):
Note: See TracChangeset
for help on using the changeset viewer.