Asynchronously performs the core dispose logic. A task representing the asynchronous dispose operation.
()
| 708 | /// </summary> |
| 709 | /// <returns>A task representing the asynchronous dispose operation.</returns> |
| 710 | protected virtual async ValueTask DisposeAsyncCore() |
| 711 | { |
| 712 | if (this.SessionId is not null) |
| 713 | { |
| 714 | try |
| 715 | { |
| 716 | await this.ExecuteAsync(DriverCommand.Quit, null).ConfigureAwait(false); |
| 717 | } |
| 718 | catch (NotImplementedException) |
| 719 | { |
| 720 | } |
| 721 | catch (InvalidOperationException) |
| 722 | { |
| 723 | } |
| 724 | catch (WebDriverException) |
| 725 | { |
| 726 | } |
| 727 | finally |
| 728 | { |
| 729 | this.SessionId = null!; |
| 730 | } |
| 731 | } |
| 732 | |
| 733 | this.CommandExecutor.Dispose(); |
| 734 | } |
| 735 | |
| 736 | private static void UnpackAndThrowOnError(Response errorResponse, string commandToExecute) |
| 737 | { |
no test coverage detected