附件案例

附件案例會測試傳送和接收附件。

此案例的目標是不是探索託管服務端點。 此案例假設在開始此案例之前,已探索或提供這些端點。

在每個情況下,傳送至 TestDevice 的附件將會Dpws1.jpg,而從 TestDevice 收到的附件將會Dpws2.jpg。 附件應該藉由將預期的附件複本載入記憶體中,並在接收的附件上執行位元組對位元組記憶體比較,來驗證附件。

如需詳細資訊,請參閱 WSDBIT 測試環境中的初始測試裝置安裝圖表。

案例 用戶端動作 伺服器動作 Pass-Fail準則
3.1 呼叫 OneWay 附件方法
3.1.1 使用 呼叫 AttachmentService

- wsa:Action == http://schemas.example.org/AttachmentService/OneWayAttachmentOneWay方法- http:\//testdevice.interop/AttachmentService1 將會使用服務。
- 請參閱AttachmentService WSDL
- 使用Dpws1.jpg做為傳送至裝置之附件的資料。
驗證附件資料。 伺服器正確地驗證附件資料。 伺服器會收到Dpws1.jpg。
3.2 呼叫 TwoWay 附件方法
3.2.1 使用下列專案呼叫 AttachmentService 的TwoWay方法:
-
wsa:Action == http://schemas.example.org/AttachmentService/TwoWayAttachmentRequest - 將會 http://testdevice.interop/AttachmentService1 使用服務。
- 請參閱AttachmentService WSDL
- 使用 Dpws1.jpg 作為傳送至裝置之附件的資料。
- 驗證附件資料。
- 傳送TwoWayAttachmentResponse
- wsa:Action == http://schemas.example.org/AttachmentService/TwoWayAttachmentResponse
- 請參閱AttachmentService WSDL
- 使用Dpws2.jpg做為傳回給用戶端之附件的資料。
伺服器會正確驗證附件資料,而用戶端會收到回應。 伺服器會收到Dpws1.jpg。
3.2.2 驗證 TwoWayAttachmentResponse中收到的附件資料。 用戶端會收到Dpws2.jpg。 不做任何動作。 用戶端會正確驗證附件資料。