---
schema_version: "1"
id: 51418d717add1cf82ac0277a3a3e3bb991f27f2538a6d9560923a464125f7906
title: Verify イベントプロセッサー
collection: mulesoft
version: current
locale: ja-jp
portal_url: https://docs.salesforce.com/mulesoft/current/ja-jp/munit/3.0/verify-event-processor.md
canonical_url: https://docs.mulesoft.com/jp/munit/3.0/verify-event-processor
source_site: docs.mulesoft.com
content_type: documentation
content_hash: 6dd53a4dfdf3b98f2a2903e8baa4ec86d2a0a5a11142e308e75b441c0434348b
description: MuleSoft Documentation Site
release: "3.0"
latest: false
---
# Verify イベントプロセッサー

Verify イベントプロセッサーでは、プロセッサーがコールされたかどうかを確認できます。

たとえば、特定のプロセッサーが、特定の属性セットを使用して、特定の回数コールされたかどうかを検証できます。

検証を定義すると、検証が成功しなかった場合にテストを失敗するよう MUnit に指示が伝えられます。

モックを作成していなくても、あらゆるプロセッサーに対して検証を定義できます。

```xml
<munit-tools:verify-call processor="http:request" atLeast="1">
   <munit-tools:with-attributes>
       <munit-tools:with-attribute attributeName="method" whereValue="#['GET']" />
   </munit-tools:with-attributes>
</munit-tools:verify-call>
```

<table class="tableblock frame-all grid-all fit-content spread">
<colgroup>
<col>
<col>
</colgroup>
<thead>
<tr>
<th class="tableblock halign-left valign-top">属性名</th>
<th class="tableblock halign-left valign-top">説明</th>
</tr>
</thead>
<tbody>
<tr>
<td class="tableblock halign-left valign-top"><p class="tableblock"><code>eventProcessor</code></p></td>
<td class="tableblock halign-left valign-top"><p class="tableblock">どのイベントプロセッサーを模擬するかを説明します。この説明は ​<code>{name-space}:{event-processor-name}</code>​ の形式を使用します。正規表現をサポートします。</p></td>
</tr>
<tr>
<td class="tableblock halign-left valign-top"><p class="tableblock"><code>times</code></p></td>
<td class="tableblock halign-left valign-top"><p class="tableblock"><strong>(デフォルト = 1)</strong>​ イベントプロセッサーが ​<em>N</em>​ 回および ​<em>N</em>​ 回のみコールされた場合に検証が成功したとして定義します。</p></td>
</tr>
<tr>
<td class="tableblock halign-left valign-top"><p class="tableblock"><code>atLeast</code></p></td>
<td class="tableblock halign-left valign-top"><p class="tableblock">イベントプロセッサーのコール回数が ​<em>N</em>​ 回以上の場合に検証が成功したとして定義します。</p></td>
</tr>
<tr>
<td class="tableblock halign-left valign-top"><p class="tableblock"><code>atMost</code></p></td>
<td class="tableblock halign-left valign-top"><p class="tableblock">イベントプロセッサーのコール回数が ​<em>N</em>​ 回以下の場合に検証が成功したとして定義します。</p></td>
</tr>
</tbody>
</table>

属性 ​`times`​、​`atLeast`​、​`atMost`​ は相互に排他的です。

`eventProcessor`​ 属性は正規表現を受け入れます。たとえば、​`.*:request`​ と同じ検証を作成して、イベントプロセッサーが属している名前空間に関係なく、request という名前のイベントプロセッサーを検証できます。正規表現の言語は Java と同じです。

## [](#関連情報)関連情報

- [Assert That イベントプロセッサー](https://docs.mulesoft.com/jp/munit/3.0/assertion-event-processor)
- [Fail イベントプロセッサー](https://docs.mulesoft.com/jp/munit/3.0/fail-event-processor)
- [Run Custom イベントプロセッサー](https://docs.mulesoft.com/jp/munit/3.0/run-custom-event-processor)
- [Set イベントプロセッサー](https://docs.mulesoft.com/jp/munit/3.0/set-event-processor)
- [Mock When イベントプロセッサー](https://docs.mulesoft.com/jp/munit/3.0/mock-event-processor)