@@ -33,7 +33,23 @@ public void Main_IntelliTectIndexHtmlArgs_DownloadFile()
3333 IntelliTect . TestTools . Console . ConsoleAssert . Expect (
3434 expected , ( ) => result = Program . Main ( args ) ) ;
3535 }
36- catch ( AggregateException exception ) when ( exception . InnerException is System . Net . Http . HttpRequestException )
36+ catch ( AggregateException exception ) when (
37+ exception . InnerException is System . Net . Http . HttpRequestException ||
38+ exception . InnerException is System . Net . Sockets . SocketException ||
39+ exception . InnerException is TaskCanceledException ||
40+ exception . InnerException is System . Net . NetworkInformation . NetworkInformationException )
41+ {
42+ Assert . Inconclusive ( "Unable to download the file. Check your internet connection." ) ;
43+ }
44+ catch ( System . Net . Http . HttpRequestException )
45+ {
46+ Assert . Inconclusive ( "Unable to download the file. Check your internet connection." ) ;
47+ }
48+ catch ( System . Net . Sockets . SocketException )
49+ {
50+ Assert . Inconclusive ( "Unable to download the file. Check your internet connection." ) ;
51+ }
52+ catch ( TaskCanceledException )
3753 {
3854 Assert . Inconclusive ( "Unable to download the file. Check your internet connection." ) ;
3955 }
@@ -48,7 +64,23 @@ public void Main_GoodArgs_DownloadFile()
4864 {
4965 Assert . AreEqual ( 0 , Program . Main ( args ) ) ;
5066 }
51- catch ( AggregateException exception ) when ( exception . InnerException is System . Net . Http . HttpRequestException )
67+ catch ( AggregateException exception ) when (
68+ exception . InnerException is System . Net . Http . HttpRequestException ||
69+ exception . InnerException is System . Net . Sockets . SocketException ||
70+ exception . InnerException is TaskCanceledException ||
71+ exception . InnerException is System . Net . NetworkInformation . NetworkInformationException )
72+ {
73+ Assert . Inconclusive ( "Unable to download the file. Check your Internet connection." ) ;
74+ }
75+ catch ( System . Net . Http . HttpRequestException )
76+ {
77+ Assert . Inconclusive ( "Unable to download the file. Check your Internet connection." ) ;
78+ }
79+ catch ( System . Net . Sockets . SocketException )
80+ {
81+ Assert . Inconclusive ( "Unable to download the file. Check your Internet connection." ) ;
82+ }
83+ catch ( TaskCanceledException )
5284 {
5385 Assert . Inconclusive ( "Unable to download the file. Check your Internet connection." ) ;
5486 }
0 commit comments