download the execution video file if the scenario fails or the video is enabled,
        renaming the file to scenario name and removing the video file in the server.
             GGR request: http://<username>:<password>@<ggr_host>:<ggr_port>/video/<session_id>
        selenoid request: http://<username>:<password>@<ggr_host>:<ggr_port>/video/<session_id>.mp4
        :param scenario_name: scenario name
        :param timeout: threshold until the video file is downloaded

def download_session_video(self, scenario_name, timeout=5):
        """
        download the execution video file if the scenario fails or the video is enabled,
        renaming the file to scenario name and removing the video file in the server.
             GGR request: http://<username>:<password>@<ggr_host>:<ggr_port>/video/<session_id>
        selenoid request: http://<username>:<password>@<ggr_host>:<ggr_port>/video/<session_id>.mp4
        :param scenario_name: scenario name
        :param timeout: threshold until the video file is downloaded
        """
        # Download video only in linux nodes with video enabled
        if (self.driver_wrapper.get_driver_platform().lower() != 'linux' or
                not self.driver_wrapper.config.getboolean_optional('Capabilities', 'enableVideo')):
            return

        path_file = os.path.join(self.videos_directory, '%s.%s' % (scenario_name, MP4_EXTENSION))
        if self.driver_wrapper.server_type == 'selenoid':
            filename = '%s.%s' % (self.session_id, MP4_EXTENSION)
        else:
            filename = self.session_id
        video_url = '{}/video/{}'.format(self.server_url, filename)
        # download the execution video file
        if self.browser_remote:
            self.__download_file(video_url, path_file, timeout)
        # remove the video file if it does exist
        self.__remove_file(video_url)