次の方法で共有


ReactiveAssert.Throws<TException> メソッド (Action, String)

指定されたアクションがジェネリック パラメーターで指定された型の例外をスローすることをアサートします。

Namespace:Microsoft.Reactive.Testing
アセンブリ: Microsoft.Reactive.Testing (Microsoft.Reactive.Testing.dll)

構文

'Declaration
Public Shared Sub Throws(Of TException As Exception) ( _
    action As Action, _
    message As String _
)
'Usage
Dim action As Action
Dim message As String

ReactiveAssert.Throws(action, message)
public static void Throws<TException>(
    Action action,
    string message
)
where TException : Exception
public:
generic<typename TException>
where TException : Exception
static void Throws(
    Action^ action, 
    String^ message
)
static member Throws : 
        action:Action * 
        message:string -> unit  when 'TException : Exception
JScript does not support generic types and methods.

型パラメーター

  • TException
    チェックする例外の種類。

パラメーター

  • message
    型: System.String
    アサート エラーのエラー メッセージ。

参照

リファレンス

ReactiveAssert クラス

オーバーロードをスローする

Microsoft.Reactive.Testing 名前空間